Back to Home
Published: June 2026By Web Util Slyce Team8 min read

HTTP Status Codes — Complete Reference

A complete reference of HTTP status codes grouped by class. Look up individual codes with our HTTP Status Code Lookup tool or test API endpoints with the REST Client.

Status Code Classes

1xxInformational

Request received, continuing process.

2xxSuccess

Request successfully received, understood, and accepted.

3xxRedirection

Further action needed to complete the request.

4xxClient Error

The request contains bad syntax or cannot be fulfilled.

5xxServer Error

The server failed to fulfill a valid request.

Complete Status Code List

All common HTTP status codes with their descriptions and typical use cases.

CodeNameDescription
100ContinueThe server has received the request headers and the client should proceed to send the body.
101Switching ProtocolsThe server is switching protocols as requested by the client (e.g., upgrading to WebSocket).
102ProcessingThe server has received and is processing the request, but no response is available yet.
103Early HintsUsed to preload resources while the server prepares the final response.
200OKThe request succeeded. The response body depends on the HTTP method used.
201CreatedA new resource was created as a result of the request. Typically returned after POST requests.
202AcceptedThe request has been accepted for processing but is not yet complete.
204No ContentThe request succeeded but there is no content to return. Commonly used for DELETE operations.
206Partial ContentThe server is delivering only a portion of the resource (used for range requests and video streaming).
301Moved PermanentlyThe resource has been permanently moved to a new URL. Search engines update their indexes.
302FoundThe resource is temporarily at a different URL. The HTTP method may change for the redirect.
303See OtherThe response is available at another URL via GET. Used in POST-Redirect-GET patterns.
304Not ModifiedThe resource has not changed since the last request. Used for caching with conditional headers.
307Temporary RedirectLike 302 but the HTTP method must not change during the redirect.
308Permanent RedirectLike 301 but the HTTP method must not change during the redirect.
400Bad RequestThe server cannot process the request due to invalid syntax or malformed data.
401UnauthorizedAuthentication is required. The client must provide valid credentials.
403ForbiddenThe client is authenticated but does not have permission to access the resource.
404Not FoundThe requested resource does not exist. The most widely recognized HTTP error code.
405Method Not AllowedThe HTTP method is not supported for this endpoint.
408Request TimeoutThe server timed out waiting for the client to send the complete request.
409ConflictThe request conflicts with the current state of the server (e.g., duplicate resource).
410GoneThe resource is permanently gone and will not be available again.
415Unsupported Media TypeThe request's Content-Type is not supported by the server.
422Unprocessable ContentThe request body is syntactically correct but semantically invalid.
429Too Many RequestsThe client has exceeded the rate limit. Retry-After header indicates when to retry.
500Internal Server ErrorA generic error when the server encounters an unexpected condition.
502Bad GatewayThe server received an invalid response from an upstream server.
503Service UnavailableThe server is temporarily unable to handle the request (maintenance or overload).
504Gateway TimeoutThe server did not receive a timely response from an upstream server.
505HTTP Version Not SupportedThe server does not support the HTTP protocol version used in the request.

Quick Tips

Use the right class

Always return 2xx for success, 4xx for client errors, and 5xx for server errors. Consistent status codes help API consumers and monitoring tools.

Include error details

For 4xx and 5xx responses, include a descriptive JSON body with an error code and message to help clients debug the issue.

Respect 429 rate limits

Always include a Retry-After header with 429 responses so clients know when to retry their requests.

Use 308 for method-preserving redirects

Use 308 instead of 301 when you need to preserve the HTTP method (e.g., POST data should remain POST on the redirected URL).

Frequently Asked Questions

What is the difference between 401 and 403?

401 Unauthorized means you are not authenticated (logged in). 403 Forbidden means you are authenticated but do not have permission to access the resource.

When should I use 201 vs 200?

Use 201 Created when a new resource is created (typically after POST). Use 200 OK for successful GET, PUT, PATCH, and POST operations that don't create a new resource.

What is the difference between 301 and 308?

Both indicate permanent redirects. 301 may change POST to GET (older browsers). 308 preserves the HTTP method. Use 308 when method preservation matters.

Should I return 404 or 403 for hidden resources?

Some APIs return 404 instead of 403 to avoid revealing the existence of resources to unauthorized users. This is a security best practice for sensitive systems.