Each time you visit a web page, a bureaucratic exchange takes place between your computer’s web browser and a distant web server.
Your web browser (called the “client”) begins the exchange by submitting a request to the web server for code, images, and other information.
The web server, always on the alert, returns a tiny message that says, “I received your request and here is what you can expect in the next few moments.”
This tiny message, including a server response code, is helpful to both the waiting client and human beings optimizing the experience.
Server response codes may appear to be errors at first glance; they’re most obvious when what the user wants to happen, doesn’t. On deeper inspection, these informational codes exist for every properly functioning online interaction. Server response codes, also called status codes, are feedback that your website is built correctly and web server functioning as intended.
Status Code Ranges
A status code’s leading number indicates its general meaning, making the codes predictable even if you don’t know the details. Every career SEO ought to know these by heart.
2xx – Successful
The general goal is to send the client to a web page with this response code range.
3xx – Redirection
These frequently misunderstood response codes help update the client’s outdated request.
4xx – Client Error
The request went wrong and the error is by the client. The most frequent response in this range is a broken link—the client requests information not existing on the server.
5xx – Server Error
The request went wrong and the error is by the server. Fixing this generally requires developer intervention.
Typical Status Codes
A large number of status codes are reserved by consensus, so web professionals can share an understanding of standard responses. The codes below appear regularly when you’re responsible for a website experience.
200 – OK
A 200 response from the server means, “Everything is great, and I’m sending the information you requested.”
This response code is generally ideal. Every first time a web page loads in your browser, this is the code received. To a search engine crawler, a 200 code says “I want you to keep this link as-is in your index.”
How could this response be an error? A few weeks ago I was looking to buy a shirt. A specific brand ranked well in search results and I immediately found pages of product links from their site that fit what I wanted. I clicked on the first product link and landed on the correct page, but there was no way to choose options or buy the shirt.
I went back to the search results and tried every link from that brand on the first page, with the same result.
With some research, I found that their web server showed a 200 response for every page that ever existed on their site. Because of this, old products were not removed from the search index and outranked buyable products in search results.
301 – Redirect Permanently
A permanent redirect acknowledges the client’s request and says, “That information now resides somewhere else.”
Instead of loading the old information, the server begins an updated request—a 301 response leads to a 200 response from the new location.
If the client is a search engine, the requested location is replaced by the new location in a search index.
A 301 response is ideal for correcting visitors who come to the wrong version of your domain, like non-www redirecting to www. This code is also great when you update and move content within your site. The idea is to make sure visitors to the old content are redirected to the updated content instead.
This response code is an error when the old location is still relevant, should be indexed, and needs to retain indexing signals. It’s also an error when the new location isn’t relevant to the old location; misuse of redirects is a common spam indicator.