We all know HTTP even if we are not from technical background. Website addresses start with http. The full form of http is Hypertext Transfer Protocol which is the pillar of data communication for the World Wide Web, that is the internet. In other words, HTTP is a set of protocols used in collaborative hypermedia information system. HTTP contains hypertext documents which are used in pointing to resources which can be easily accessed by any user via mouse clicks, finger touch or any other input methods.
In this article, we shall talk about the HTTP Status Code Errors. HTTP is based on the client server architecture, where the web server is the server and the browsers, search engine act like clients. HTTP has a list of status response codes. These codes are generated by a server in response to the request made by the client to the server. If the response is successful, then well and good. Else, a Status code error is generated. Let’s have a look at the complete list of HTTP Status Code Errors.
HTTP Status Codes are classified into five types: 1XX, 2XX, 3XX, 4XX, 5XX
1xx
This type of status code indicates that the client has initiated a request, which has been received by the web server and under process.
The codes that fall under these category are
100 Continue: This code means the server received only a part of the entire request lodged by the client. Thus, the client can continue sending the request unless it is not discarded or rejected from server end. Hence, the name Continue.
101 Switching Protocols: This code indicates that the server is ready to switch protocols as requested by the client.
2xx
This type of code is generated when the request initated by the client was delivered to the server and the server could successfully process it. It is an acknowledgment from the server end.
200 OK: This one represents the standard response to successful HTTP requests by the clients. If everything is fine and the webpahges behaving as expected, the server returns this value.
201 Created: The value returned when the request made by the client has been completed by the server and a new resource is created.
205 Reset Content: When the server has been able tp fulfill the client’s request successfully, but failed to return any content, then this value is returned. The webpage has to reset the document view then.
3xx
The 3xx type or codes is basically redirection code where the client has to perform additional action to accomplish an initiated request.
300 Multiple Choices: This code represents multiple choice for the client-initiated resources.The client can select a link of maximum 5 addresses.
302 Found: When the client-initiated request for the resources is found but at a location different to that expected normally. This indicated that it has been temporarily moved to other resource.
304 Not Modified: This value indicates that the resource has not been modified since the version specified by the request headers If-Modified-Since or If-None-Match. Thus there is no requirement to retransmit the resource because the client already has a copy of the same resource.
4xx
The 4xx codes are used in scenarios when the error has been caused by the client. If the request registered by the client has some error in syntax, then these codes are returned.
400 Bad Request: When the client has sent wrong request in terms of syntax, deceptiove rotuing request, framing, then the server fails to process the request. So, it is called a bad request.
401 Unauthorized: When the client has provided invalid authentication credentials.
403 Forbidden: When the client does not have the authority to view the content, the 403 forbidden code is returned.
404 Not Found: This is the most popular code error users see. This value is returned when the server fails to find the client initiated request.
405 Method Not Allowed: When the method requested by the client is supported by the hosting server, but not by the resources requested by the client.
408 Request Timeout: When the server fails to receive a complete request from the client. This type of error arises from data loss during communication between the client and the server.
410 Gone: When the server fails to find the client initiated request page or resources. This error has similarity with 404 except the fact that it is permanent and thus the term “Gone”.
5xx
When the server is aware of the fact that it has encountered an error. If the server is not responsing to a HEAD request, the server should include an entity containing an explanation of the error situation and also mention if the error is temporary, recoverable or permanent and irrecoverable.
500 Internal Server Error: Generated by the third party plugins or faulty plugins.
501 Not Implemented: When the web server issue an error becuase the server does not support the functionality requested by the client. it can be solved by the host.
502 Bad Gateway: When the resource requested by the server to the database will takes a long time to process and thus gets cancelled eventually by the web server.
503 Service Unavailable: When the server is overloaded with too many requests and is fails to hprocess every request within the deadline.
504 Gateway Timeout: When the server fails to receive a response from the upstream server. When the client initiated requests involve two servers to be working, one acts as the gateway. The gateway server then forwards the request to the second server. IF the first server cannot forward the response to the second within time, then this value is returned.
That’s all!