HTTP Status Codes Reference

Complete list of HTTP response status codes with explanations and common use cases.

1xx — Informational

CodeNameDescription
100ContinueThe server has received the request headers and the client should proceed to send the request body.
101Switching ProtocolsThe server is switching protocols as requested by the client (e.g., upgrading to WebSocket).
102ProcessingThe server has received the request and is processing it, but no response is available yet (WebDAV).
103Early HintsUsed to return some response headers before the final response, allowing preloading of resources.

2xx — Success

CodeNameDescription
200OKThe request succeeded. The response body contains the requested resource. Most common success response.
201CreatedThe request succeeded and a new resource was created. Typically returned after POST requests.
202AcceptedThe request has been accepted for processing, but processing has not been completed (async operations).
204No ContentThe request succeeded but there's no content to return. Common for DELETE requests.
206Partial ContentThe server is returning partial content as requested by the Range header. Used for resumable downloads.

3xx — Redirection

CodeNameDescription
301Moved PermanentlyThe resource has been permanently moved to a new URL. Browsers will cache this redirect. SEO-friendly.
302FoundThe resource has been temporarily moved to a different URL. The original URL should still be used.
303See OtherThe response can be found at another URL using GET. Often used after POST to redirect to a result page.
304Not ModifiedThe resource has not been modified since the last request. The client can use its cached version.
307Temporary RedirectLike 302, but the request method must not change. POST stays POST.
308Permanent RedirectLike 301, but the request method must not change. POST stays POST.

4xx — Client Errors

CodeNameDescription
400Bad RequestThe server cannot process the request due to malformed syntax, invalid parameters, or bad formatting.
401UnauthorizedAuthentication is required and has failed or not been provided. Include a WWW-Authenticate header.
403ForbiddenThe server understood the request but refuses to authorize it. Authentication won't help.
404Not FoundThe server cannot find the requested resource. The most famous HTTP error code.
405Method Not AllowedThe HTTP method is not allowed for this resource (e.g., POST on a read-only endpoint).
408Request TimeoutThe server timed out waiting for the request from the client.
409ConflictThe request conflicts with the current state of the resource (e.g., duplicate entry, edit conflict).
410GoneThe resource has been permanently deleted and will not be available again. Unlike 404, this is intentional.
413Payload Too LargeThe request body exceeds the server's size limits (e.g., file upload too large).
415Unsupported Media TypeThe server does not support the media type of the request body (check Content-Type header).
422Unprocessable EntityThe request is syntactically correct but semantically invalid (e.g., validation errors).
429Too Many RequestsThe client has sent too many requests in a given time period (rate limiting). Check Retry-After header.
451Unavailable for Legal ReasonsThe resource is unavailable due to legal demands (censorship, DMCA, etc.).

5xx — Server Errors

CodeNameDescription
500Internal Server ErrorA generic server error. Something went wrong but the server can't be more specific about the cause.
501Not ImplementedThe server does not support the functionality required to fulfill the request.
502Bad GatewayThe server acting as a gateway received an invalid response from the upstream server.
503Service UnavailableThe server is temporarily unable to handle the request (overloaded, maintenance). Check Retry-After.
504Gateway TimeoutThe server acting as a gateway did not receive a timely response from the upstream server.