NOTE
2.3 HTTP Status Codes
English translation of the original VNote “HTTP Status Codes”, preserving the original list of status codes and explanations.
This is a historical learning note and may contain outdated or incomplete understanding.
1. 1xx
Status codes that indicate a provisional response and require the requester to continue the operation.
2. 2xx
Status codes that indicate the request was successfully processed.
-
200 (Success) The server successfully processed the request. Usually, this means the server provided the requested web page.
-
201 (Created) The request succeeded and the server created a new resource.
-
202 (Accepted) The server accepted the request but has not yet processed it.
-
203 (Non-Authoritative Information) The server successfully processed the request, but the returned information may come from another source.
-
204 (No Content) The server successfully processed the request but did not return any content.
-
205 (Reset Content) The server successfully processed the request but did not return any content.
-
206 (Partial Content) The server successfully processed part of a GET request.
3. 3xx
Indicates that further action is required to complete the request. These status codes are usually used for redirection.
-
301: Permanent redirect. Indicates that this web page has been permanently moved to another address.
-
302: Temporary redirect. Used when a web page URL needs to change for a short period.
-
303 (See Other) The server returns this code when the requester should use a separate GET request to retrieve the response from a different location.
-
304 (Not Modified) The requested web page has not been modified since the last request. When the server returns this response, it does not return the web-page content.
-
305 (Use Proxy) The requester can access the requested web page only through a proxy. If the server returns this response, it also indicates that the requester should use a proxy.
-
307 (Temporary Redirect) The server currently responds to the request from a web page at a different location, but the requester should continue to use the original location for future requests.
4. 4xx
Indicates that the client request may be incorrect and prevents the server from processing it.
-
400 (Bad Request) The server does not understand the syntax of the request.
-
401 (Unauthorized) The request requires authentication. For a web page that requires login, the server may return this response.
-
403 (Forbidden) The server refuses the request.
-
404 (Not Found) The server cannot find the requested web page.
-
405 (Method Not Allowed) The method specified in the request is disabled.
-
406 (Not Acceptable) The requested web page cannot respond using the requested content characteristics.
-
407 (Proxy Authentication Required) This status code is similar to 401 (Unauthorized), but specifies that the requester should authenticate to use the proxy.
-
408 (Request Timeout) The server timed out while waiting for the request.
-
409 (Conflict) The server encountered a conflict while completing the request. The server must include information about the conflict in the response.
-
410 (Gone) If the requested resource has been permanently deleted, the server returns this response.
-
411 (Length Required) The server does not accept requests that do not contain a valid Content-Length header field.
-
412 (Precondition Failed) The server did not meet one of the preconditions set by the requester in the request.
-
413 (Request Entity Too Large) The server cannot process the request because the request entity is too large and exceeds the server’s processing capacity.
-
414 (Request-URI Too Long) The requested URI, usually a URL, is too long for the server to process.
-
415 (Unsupported Media Type) The format of the request is not supported by the requested page.
-
416 (Requested Range Not Satisfiable) The server returns this status code if the page cannot provide the requested range.
-
417 (Expectation Failed) The server did not meet the requirements of the
Expectrequest-header field.
5. 5xx
Indicates that the server encountered an internal error while trying to process the request.
-
500 (Internal Server Error) The server encountered an error and could not complete the request.
-
501 (Not Implemented) The server does not have the functionality required to complete the request. For example, this code may be returned when the server cannot recognize the request method.
-
502 (Bad Gateway) The server, acting as a gateway or proxy, received an invalid response from an upstream server.
-
503 (Service Unavailable) The server is currently unavailable due to overload or maintenance downtime. Usually, this is only a temporary state.
-
504 (Gateway Timeout) The server, acting as a gateway or proxy, did not receive a timely response from the upstream server.
-
505 (HTTP Version Not Supported) The server does not support the HTTP protocol version used in the request.
Discussion
Sign in with GitHub to comment. Discussions are stored as GitHub Issues.View on GitHub