Error Page Codes
What are Error Codes?
All HTTP requests (the type of requests generated by your browser when you attempt to load a page) generate a status code. However, your browser will generally only display a status code associated with an error after an attempted action fails.
There are 5 classes of status codes, and the term error codes specifically refer to the two classes of status codes that indicate these errors. This article will cover the following codes:
- What is a Client Error Code?
- 400 : Bad Request
- 401 : Authorization Required
- 403 : Forbidden
- 404 : Not Found
- 405 : Method Not Allowed
- 406 : Not Acceptable (encoding)
- 407 : Proxy Authentication Required
- 408 : Request Timed Out
- 409 : Conflicting Request
- 410 : Gone
- 411 : Content Length Required
- 412 : Precondition Failed
- 413 : Request Entity Too Long
- 414 : Request URI Too Long
- 415 : Unsupported Media Type
- 421 : Too Many Connections
- What is a Server Error Code?
- Custom Error Pages
What is a Client Error Code?
Client Error Codes begin with the number 4, such as 404 or 403 (two of the most common client-side errors). A Client Error Code indicates an issue with the request and that the request itself must be changed to get a different result.
For example, if you get a 404 error code, it means the resource you requested does not exist. The request may be incorrect, or the resource may have been removed, but the server is functioning correctly, and the error is that the user is requesting something that is not there.
Continue reading for an index of possible 4XX Client Error Codes. ⤵
400 : Bad Request
When the HTTP request completely fails to conform to the HTTP protocol, the Web server may identify it as being malformed and serve this error page. This indicates that the request was not in a format that the server understood and could not be served.
This almost universally indicates an error with the programming, either in the client or in the server.
401 : Unauthorized
Access to the URL resource requires user authentication, which either has not yet been provided or which has been provided but failed. This is commonly known as password protection. Unless you have a good reason to do so, it is not recommended to redirect a 401 error.
403 : Forbidden
The request was a legal request, but the server is refusing to respond to it. Unlike a 401 Unauthorized response, authenticating will make no difference. This is usually due to a scripting or file permissions issue. For more information on 403 errors, please follow the link below:
404 : Not Found
This response code is an error page that indicates the visitor was able to communicate with the server, but either the server could not find what was requested, or it was configured not to fulfill the request and not reveal the reason. Error 404 should not be confused with "server not found" or similar errors in which a connection to the destination server cannot be made at all. For more information on 404 errors, please review the following article:
405 : Method Not Allowed
This error is rarely seen as it specifically indicates that the email client that is being used is attempting to access the server via a prohibited method. It would indicate an issue with the client software.
406 : Not Acceptable
When requesting information from the server, the browser or client also includes a specification with its request for the format in which it wants the information returned.
If the server is unable to accommodate this request, it will return a 406 Not Acceptable error page. This error occurs very infrequently in Web browsers because most browsers will accept any data returned from the Web server.
If you experience this error, you would need to refer to the technical support for the client sending the request.
407 : Proxy Authentication Required
This error page is an issue with authentication, similar to a 401 error page. The difference is largely in how the server requires the authentication to be provided. While a server generating a 401 error requires direct authentication, a 407 error would be generated by a server configured to require authentication via a proxy.
408 : Request Timed Out
This error page is caused when the servers drop the connection to your client because too much time has passed between the initial connection being established and data transmission.
Many potential issues can cause this problem, including load on the client matching, issues with your local area network, issues with your ISP, issues with the route to the server, and lastly, it could potentially be caused by high load on the server itself.
If you receive this error page, it is recommended that you first check your traceroute for any issues or delays:
409 : Conflicting Request
When the request you have made conflicts with an established rule, the server may generate a 409 error page to indicate two requests that conflict with each other. This issue is rarely caused by standard Web server authority or security as those processes will generate different errors.
A 409 error usually requires an application-specific issue that is not defined by the HTTP protocol.
410 : Gone
Sometimes a server can provide a 410 error page instead of a 404 error. These error pages are fundamentally the same, indicating that a resource that has been requested is not available. However, the 410 error page code provides the additional information that the resource previously existed but is no longer present.
If the server has no method for identifying if a resource previously existed, it will serve the more common 404 error page.
411 : Content-Length Required
When using HTTP methods that involve placing data on a server, such as PUT or POST, the server may require the length of the data to be specified. If the length must be specified and the request fails to do so, this error page will be returned.
This issue will require the restructuring of the request to include the required information to resolve it.
412 : Precondition Failed
An HTTP client using an HTTP data stream to send data to the server is able to include specifications for the stream, known as Preconditions. If a precondition was specified but not met, this error page would be generated by the server.
As this issue may only be generated when a client-side application does not meet the specifications set by itself, this would need to be diagnosed as an issue with the client and identifying the precondition that is not being met.
413 : Request Entity Too Long
When the HTTP data stream sent by the client to the server is too large, the server will generate this error page. What is or is not "too large" depends on the client's request and restrictions placed on the server.
This issue would require ensuring that the correct method is being used to upload your data to the server and possibly using a different method, such as FTP rather than HTTP, to upload your data to the server.
414 : Request URI Too Long
A 414 error page requires both that you use a URL formed in a way that successfully reaches a server and that is too long for the server to process based on its restrictions. Due to both of these needing to be true, this error is rarely generated.
If you experience this error page, it is recommended that you recode the website to require a shorter URL to navigate to.
415 : Unsupported Media Type
When a client uses an HTTP data stream to transfer a URL resource to the server, it may need to specify the media type that is being transferred. This error will be generated if any of the following criteria are met:
- If the specified media type does not match the actual media included in the request.
- If the actual media included in the request is incompatible with the current resource data.
- If the actual media included is incompatible with the method specified by the HTTP request.
Most users should not encounter this error page. It is highly indicative of programming issues with a specific feature and requires development to resolve.
To troubleshoot this issue, you would need to identify the media type that your client is attempting to transfer via HTTP, and what type of media type the request is claiming to send, and the required media type by the software on the server.
421 : Too Many Connections
The maximum number of connections from one IP is 8. If you encounter a 421 error, this means that you have exceeded this limitation. You can no longer control your FTP connections via FTP Sessions Control in cPanel; this must now be completed via your FTP client. For more information on controlling FTP sessions, please review the following article.
What is a Server Error Code?
Server Error Codes begin with the number 5, such as 500 or 503 (two of the most common server-side errors). These error pages indicate that an issue was experienced on the server that prevented it from being able to serve the request.
Unlike Client Error Codes, a Server Error Code can sometimes be temporary or intermittent caused by temporary resource issues or issues with the route the request took to reach the server or return back.
Continue reading for an index of possible 5XX Server Error Codes. ⤵
500 : Internal Server Error
Your web server encountered an unexpected condition that prevented it from fulfilling the request by the visitor. Basically, something has gone wrong, but the server can not be more specific about the error condition in its response to the visitor. For details on common causes of 500 errors, please visit the following link:
501 : Not Implemented
This status code indicates that the HTTP method of the request from the client is not understood or supported by the server. The methods currently defined by the HTTP protocol are as follows: OPTIONS, GET, HEAD, POST, PUT, DELETE, TRACE, and CONNECT.
This issue is generally indicative of an issue with the client used to access the server.
502 : Bad Gateway
This HTTP status code indicates that one server received an invalid response from another server that it was accessing while attempting to load a website or complete another request. This error page can appear in various forms, e.g., 502 Service Temporarily Overloaded, HTTP 502, 502 Proxy Error, and Temporary Error (502). This issue is commonly a network error between servers on the internet; however, some measures can be taken, such as refreshing the page, clearing your browser cache, using a different browser to load the site, or starting a new browsing session.
503 : Service Unavailable
This error is likely due to an issue on your server which will require additional assistance. Typically this can occur when your server is temporarily overloaded or undergoing maintenance. For in-depth information on this particular error, please visit the link below:
504 : Gateway Timeout
When you attempt to access a web page, the server where your action is routed through places a time limit on that request. If a response is not provided after a certain amount of time, a 504 error page may appear in your browser. 504 errors are normally a result of attempting to contact a server that is either not properly functioning or undergoing maintenance.
505 : HTTP Version Not Supported
This error is caused by a client or browser attempting to use a version of the HTTP protocol that is not supported by the web server. This is a rare error and can likely be resolved by attempting to use a client that uses the correct current standards.
Custom Error Pages
When an error code is generated, the server provides a default web page to the client. Using custom error pages allows you to brand your error pages or provide unique or very specific information when a visitor generates an error.
Check out the following article for more information on how to serve your own unique or branded pages when a customer generates an error: