Did you like our previous blog about domain hijacking? Let’s see if you know all the HTTP codes now.
Decoding HTTP status codes
HTTP status codes, typically a sequence of three numbers, are a reply from the server in response to a request made by a web browser.
A common example many might recognize is the 404 error, which signals that a particular page could not be found — a type of HTTP client error.
These codes (known as response status codes) facilitate the communication process between an internet browser and the server. They are categorized into various classes, with each class defined by the first digit in the code.
When using website monitoring, you get these HTTP statuses in alerts (based on your settings).
For example, codes starting with ‘4’, like the 404 error, are used for issues relating to the accessibility or availability of a page or site. On the other hand, a code beginning with ‘2’ typically indicates that the browser’s request was processed successfully.
|What it means
|1xx Informational response
|Found (Previously “Moved Temporarily”)
|4xx Client Error
|Method Not Allowed
|Proxy Authentication Required
|Payload Too Large
|URI Too Long
|Unsupported Media Type
|Range Not Satisfiable
|I’m a Teapot
|Too Many Requests
|Request Header Fields Too Large
|Unavailable For Legal Reasons
|5xx Server Error
|Internal Server Error
|HTTP Version Not Supported
|Variant Also Negotiates
|Network Authentication Required
Deciphering the HTTP status code directory
HTTP status codes might seem like a secret language, but they’re quite logical. Let’s decode the classes.
Class 1XX: the informational codes
100 Continue: The client can continue with its request. This preliminary response indicates that everything so far is OK and that the client should proceed with the request or ignore it if it’s already finished.
101 Switching Protocols: This code is sent in response to an upgrade request header from the client, and the server is switching the protocols according to the requester’s instructions. For example, the server might switch from HTTP 1.1 to HTTP 2.
103 Early Hints: The server sends this code to notify the client about potential redirection targets, even before the client finishes its request. This code helps optimize loading by reducing round-trip times.
Class 2XX: codes for success
- 200 OK
- 201 Created
- 202 Accepted
- 203 Non-Authoritative Information
- 204 No Content
- 205 Reset Content
- 206 Partial Content
200 OK: The request succeeded, and the resultant entity body contains the requested resource. It’s the standard response for successful HTTP requests.
201 Created: A new resource was successfully created in response to the request. This is typically the response sent after POST requests or some PUT requests.
202 Accepted: The request has been accepted for processing, but the server has not yet completed the processing.
203 Non-Authoritative Information: The server successfully processed the request but is returning a cache or proxy response.
204 No Content: The server successfully processed the request and isn’t returning any content. This status is often used for DELETE requests where returning a body with the status of the deleted element is not necessary.
205 Reset Content: The server processed the request, and the user agent should reset the document view. This could be used when the server has fulfilled the request and desires that the user agent reset the GUI.
206 Partial Content: The server is delivering a part of the requested resource due to a range header sent by the client. For instance, if you’re downloading a large file, the server might send the file in smaller parts rather than all at once.
Class 3XX: the redirection codes
- 300 Multiple Choices
- 301 Moved Permanently
- 302 Found
- 303 See Other
- 304 Not Modified
- 307 Temporary Redirect
- 308 Permanent Redirect
TIP: Catch redirects and get alerts with UptimeRobot using the new “Don’t follow redirects” option.
300 Multiple Choices: The server has several actions to choose from, depending on the client. For instance, there might be different file formats or word languages to choose from.
301 Moved Permanently: The requested resource has moved permanently. Links to the old URL are automatically redirected to the new URL.
302 Found: This response code means that the URI of the requested resource has been temporarily changed. However, future requests should still use the original URI.
303 See Other: The server sends this response to direct the client to another URL. This status code is commonly used to redirect after a PUT or POST request.
304 Not Modified: The client can use a cached version of the requested resource.
307 Temporary Redirect: The requested resource has been temporarily moved to a different URL.
308 Permanent Redirect: This is similar to a 301, but it indicates that all future requests should repeat the original request using the new URL.
Class 4XX: the client error codes
- 400 Bad Request
- 401 Unauthorized
- 402 Payment Required
- 403 Forbidden
- 404 Not Found
- 405 Method Not Allowed
- 406 Not Acceptable
- 407 Proxy Authentication Required
- 408 Request Timeout
- 409 Conflict
- 410 Gone
- 411 Length Required
- 412 Precondition Failed
- 413 Payload Too Large
- 414 URI Too Long
- 415 Unsupported Media Type
- 416 Range Not Satisfiable
- 417 Expectation Failed
- 418 I’m a teapot
- 422 Unprocessable Entity
- 425 Too Early
- 426 Upgrade Required
- 428 Precondition Required
- 429 Too Many Requests
- 431 Request Header Fields Too Large
- 451 Unavailable For Legal Reasons
- 499 Client Closed Request
400 Bad Request: The server could not understand the request due to malformed syntax. The client should modify the request before resending.
401 Unauthorized: The request requires authentication. The client should resend the request with the required credentials.
402 Payment Required: Reserved for future use, this code was originally meant to signal that the client must pay to access the requested resource.
403 Forbidden: The server has denied the request. Unlike a 401 Unauthorized response, authenticating won’t make a difference.
404 Not Found: The server can’t find the requested resource. Links that lead to a 404 page are often called broken or dead links.
405 Method Not Allowed: The HTTP method used in the request is not supported for the requested resource.
406 Not Acceptable: The server cannot produce a response that matches the list of acceptable formats.
407 Proxy Authentication Required: The proxy requires authentication before forwarding the request to the server.
408 Request Timeout: The server didn’t receive a complete request from the client within the required time.
409 Conflict: The request couldn’t be processed because of a conflict in the request, such as an edit conflict in the case of multiple updates.
410 Gone: The requested resource is no longer available and will not be available again.
411 Length Required: The server refuses to accept the request without a defined Content-Length.
412 Precondition Failed: The server does not meet one of the preconditions that the requester put on the request.
413 Payload Too Large: The request is larger than the server is willing or able to process.
414 URI Too Long: The URI provided was too long for the server to process.
415 Unsupported Media Type: The request entity has a media type which the server or resource does not support.
416 Range Not Satisfiable: The client has asked for a portion of the file, but the server cannot supply that portion.
417 Expectation Failed: The server cannot meet the requirements of the Expect request-header field.
418 I’m a teapot: This code was defined in 1998 as one of the traditional IETF April Fools’ jokes.
422 Unprocessable Entity: The request was well-formed but was unable to be followed due to semantic errors.
425 Too Early: Indicates that the server is unwilling to risk processing a request that might be replayed.
426 Upgrade Required: The client should switch to a different protocol.
428 Precondition Required: The origin server requires the request to be conditional.
429 Too Many Requests: The user has sent too many requests in a given amount of time.
431 Request Header Fields Too Large: The server is unwilling to process the request because its header fields are too large.
451 Unavailable For Legal Reasons: A server operator has received a legal demand to deny access to a resource or to a set of resources that includes the requested resource.
499 Client Closed Request: The connection was closed by client while HTTP server is processing its request, making server unable to send the HTTP header back.
Class 5XX: the server error codes
- 500 Internal Server Error
- 501 Not Implemented
- 502 Bad Gateway
- 503 Service Unavailable
- 504 Gateway Timeout
- 505 HTTP Version Not Supported
- 506 Variant Also Negotiates
- 507 Insufficient Storage
- 508 Loop Detected
- 510 Not Extended
- 511 Network Authentication Required
- 599 Network Connect Timeout Error
500 Internal Server Error: This is a generic error message when an unexpected condition is encountered, and no specific message is suitable.
501 Not Implemented: The server either does not recognize the request method or lacks the ability to fulfill the request.
502 Bad Gateway: The server received an invalid response when acting as a getaway.
503 Service Unavailable: The server is currently overloaded or down for maintenance.
504 Gateway Timeout: The server didn’t receive a timely response from an upstream server and couldn’t complete the request.
505 HTTP Version Not Supported: The server does not support the HTTP protocol version used in the request.
506 Variant Also Negotiates: The server has an internal configuration error, and you may need to modify its request to resolve the ambiguity.
507 Insufficient Storage: The server is unable to store the representation needed to complete the request.
508 Loop Detected: The server detected an infinite loop while processing a request with “Depth: infinity”. This status indicates that the entire operation failed.
510 Not Extended: Further extensions to the request are required for the server to fulfill it. For example, the client may need to provide additional authentication details.
511 Network Authentication Required: The client needs to authenticate itself to gain network access.
599 Network Connect Timeout Error: A network connection to the server timed out.
Bonus HTTP code
📍Although not an official error, HTTP 999 is used as a “catch-all” error code presented when a more specific error code is not provided by the server. It’s commonly used by some social media sites like LinkedIn to limit or prevent web crawlers.
The undeniable impact of HTTP status codes on SEO
Understanding the technical side of SEO can be challenging, but it’s also crucial if you want to maximize your website’s visibility. An abundance of error codes can signal to search engines like Google that your website isn’t very reliable, which can negatively impact your site’s SEO.
According to Search Engine Watch, several HTTP status codes are especially critical to SEO:
302 – This temporary redirect code tells search engines generally that the original URL will eventually be restored, so the page index is never updated for better SEO.
404 – When search engine crawlers can’t access your content, your SEO suffers.
410 – This error causes search engines to remove the page from the index immediately. This means that the page will no longer appear in search engine results.
500 – Google also doesn’t like it when servers are down, so this error can negatively affect your rankings.
503 – Search engines don’t like to see “service unavailable,” and if the error keeps happening, the search engine might de-index the page, affecting your rankings.
On the flip side, correct usage of HTTP status codes can help preserve your website’s SEO. For example, Google likes to see 301 permanent redirects for pages that are no longer available, allowing your site to retain its SEO value. 200 HTTP codes are also great to see — it means everything is working as it should, and Google loves you.
How to find the status code of a page
Understanding the status code of a web page is crucial for website administrators, developers, and SEO specialists.
Below are some effective methods to find the status code of a page using both browser-based tools and online resources.
Using browser developer tools
One of the most straightforward methods to find the status code of a web page is by using developer tools in modern web browsers. For example, in Google Chrome, users can access this feature by right-clicking on a webpage, selecting “Inspect,” and then navigating to the “Network” tab. When the user reloads the page, a list of all requests made by the page is displayed.
The first item, typically representing the page itself, will show the status code. For example, a successful load will display a 200 status code.
Using online tools and API services
For those looking for a more automated approach, numerous online tools and API services offer the functionality to check status codes in bulk.
Websites like HTTPStatus.io allow users to enter a URL and receive the status code without needing any technical know-how.
This method is particularly useful for non-developers or those conducting SEO audits.
On the more technical end, APIs such as the one provided by HTTPstatus.io offer a programmatic way to check status codes, ideal for integrating into continuous integration pipelines or for monitoring website health.
How to fix status code errors
Addressing status code errors is a vital aspect of website maintenance, ensuring both optimal performance and a positive user experience. While these errors can be diverse, they generally fall into categories indicating either client-side issues (4xx errors) or server-side problems (5xx errors).
Understanding and resolving these errors is essential for maintaining website health, improving SEO rankings, and ensuring seamless access for users. Below, we explore specific strategies to address the common categories of status code errors: 4xx, 5xx, and chained 3xx redirect errors.
How to fix 4xx errors
4xx errors are client-side errors indicating that the request made by the client cannot be processed. To fix these:
- 404 Not Found: Ensure the URL is correct. If the URL is correct but the content is missing, either restore the missing content or update the link to point to the appropriate content.
- 403 Forbidden: Check server permissions. The file or page should have the correct permissions set, allowing access to users or requesting clients.
- 401 Unauthorized: Implement proper authentication. If the resource requires authentication, ensure that the server is set up to prompt for credentials and that users have correct login details.
Addressing these errors often involves verifying and correcting URLs, updating server permissions, or ensuring proper authentication mechanisms are in place.
How to fix 5xx errors
5xx errors are server-side issues, indicating problems with the website’s server. To resolve these:
- 500 Internal Server Error: Check server logs to identify the cause. This error is generic, so logs are crucial for pinpointing the specific issue.
- 503 Service Unavailable: This often occurs due to server overload or maintenance. Ensure server capacity is adequate and consider implementing load balancers or scaling solutions if traffic volumes are high.
- 504 Gateway Timeout: Optimize server response time. Check if external resources the server is relying on, such as databases or other servers, are responding promptly.
Resolving 5xx errors usually involves a thorough investigation into server configurations, resources, and logs to identify and rectify the underlying issues.
How to find and fix chained redirect errors (Chained 3xx)
Chained redirects, multiple 3xx redirects happening in a sequence, can harm SEO and user experience. To fix these:
- Identify Chained Redirects: Use tools like redirect checker tools or browser developer tools to trace the path of a redirect chain.
- Simplify Redirects: Aim to have a single, direct redirect. This means editing the server’s configuration files to ensure that any given URL redirects directly to its final destination, rather than passing through multiple redirects.
- Regular Monitoring: Regularly audit your site for redirects, especially after making changes to the site structure or content. This helps in early detection and resolution of any unintended redirect chains.
Addressing chained redirects involves simplifying the redirect path, ensuring direct and efficient routing of URLs, and maintaining regular checks to prevent the issue from reoccurring.
Understanding HTTP status codes can give you a wealth of information about the health and performance of your website.
By paying attention to these codes and managing them effectively, you can provide a seamless user experience for your customers and maintain your website’s SEO value.
Take advantage of tools like Google Search Console and UptimeRobot to help you monitor these status codes and address any issues promptly. Remember, an informed website owner is an empowered website owner — so don’t let HTTP status codes remain a mystery!
Keeping tabs on HTTP status codes with Google search console and UptimeRobot
Google Search Console is an important tool to help you monitor and decode the various HTTP status codes your site is generating. By using the ‘Crawl Errors’ report, you can see if Google has encountered any problems when indexing your website.
While Google Search Console is comprehensive, it doesn’t explicitly identify all HTTP status codes, and you also won’t get alerts immediately when something goes wrong.
That’s where UptimeRobot steps in.
UptimeRobot will monitor your website so if your site goes down or starts generating 4xx or 5xx HTTP status codes, you’ll receive an alert.
This rapid notification allows you to quickly address issues and stay ahead of potential website hiccups that could impact your site’s SEO.
Once you detect HTTP code issues, make sure you look into it.
With UptimeRobot, you can choose which HTTP codes will be considered as UP or DOWN notifications.
Google’s John Mueller has a lot of interesting advice on how to remove errors (see the video below, where he discusses removing 404 errors from Google indexing). While this can be a long and tedious process, especially if you have a large website with many subpages, it’s crucial that you address the issues to ensure your SEO isn’t damaged.