HTTP Status Codes

52 codes — search by number or name, filter by category, click to copy.

52 results
100ContinueClient should continue sending the request body
101Switching ProtocolsServer agrees to switch protocols (e.g. WebSocket upgrade)
102ProcessingServer has received the request and is still processing it (WebDAV)
103Early HintsPreload headers sent before final response to speed up rendering
200OKStandard success response; GET, PUT, PATCH with response body
201CreatedResource was created; include a Location header with the new URL
202AcceptedRequest received but processing not yet complete; async job queued
203Non-Authoritative InformationResponse is from a proxy or cache, not the origin server
204No ContentSuccess but no response body; used for DELETE and PATCH with no return
206Partial ContentPartial response for range requests and file streaming (Range header)
207Multi-StatusMultiple independent operations in one response body (WebDAV)
208Already ReportedMembers already enumerated in a previous part of the response (WebDAV)
301Moved PermanentlyResource has permanently moved; update all links and caches
302FoundTemporary redirect; client may change POST to GET on redirect
303See OtherRedirect to a different URI using GET, typically after POST/PUT
304Not ModifiedClient cache is still fresh; skip the response body
307Temporary RedirectTemporary redirect with method preserved (POST stays POST)
308Permanent RedirectPermanent redirect with method preserved (POST stays POST)
400Bad RequestInvalid JSON, malformed syntax, or missing required fields
401UnauthorizedMissing or invalid authentication credentials
402Payment RequiredPayment needed before accessing this resource or feature
403ForbiddenAuthenticated but lacking permission to access this resource
404Not FoundResource does not exist at this URI
405Method Not AllowedHTTP method is not supported for this endpoint
406Not AcceptableServer cannot produce a response matching Accept headers
408Request TimeoutClient did not send the full request within the server's timeout
409ConflictRequest conflicts with current resource state (e.g. duplicate, version mismatch)
410GoneResource has been permanently deleted and will not return
411Length RequiredServer requires a Content-Length header in the request
412Precondition FailedA precondition header (If-Match, If-None-Match) evaluated to false
413Content Too LargeRequest body exceeds the server's configured size limit
414URI Too LongThe request URI is longer than the server can process
415Unsupported Media TypeServer cannot handle the Content-Type sent (e.g. not application/json)
416Range Not SatisfiableRange header requests a range that does not overlap the resource
418I'm a TeapotServer refuses to brew coffee because it is a teapot (RFC 2324 — an April Fools joke)
422Unprocessable EntityValid JSON syntax but fails semantic or business validation rules
423LockedResource is locked and cannot be modified (WebDAV)
424Failed DependencyRequest failed because a dependency request failed (WebDAV)
425Too EarlyServer is unwilling to process a request that might be replayed (TLS early data)
426Upgrade RequiredClient must upgrade to a different protocol (e.g. TLS)
429Too Many RequestsRate limit exceeded; include Retry-After and rate limit headers
431Request Header Fields Too LargeRequest headers are too large for the server to process
451Unavailable For Legal ReasonsResource blocked due to legal demand (government order, DMCA, etc.)
500Internal Server ErrorUnhandled server exception; log it and return a safe generic message
501Not ImplementedEndpoint is defined but not yet built or supported
502Bad GatewayUpstream server or proxy returned an invalid response
503Service UnavailableServer overloaded or down for maintenance; include Retry-After
504Gateway TimeoutUpstream server did not respond within the timeout window
505HTTP Version Not SupportedServer does not support the HTTP protocol version used in the request
507Insufficient StorageServer cannot store the representation to complete the request (WebDAV)
508Loop DetectedInfinite loop detected while processing the request (WebDAV)
511Network Authentication RequiredClient must authenticate to gain network access (captive portals)

What are HTTP Status Codes?

HTTP status codes are three-digit numbers returned by a web server in response to every HTTP request. They tell the client whether the request succeeded, failed, or needs further action. The first digit indicates the category: 1xx informational, 2xx success, 3xx redirect, 4xx client error, 5xx server error.

Status codes are the universal language between clients and servers. Returning the right code matters for API consumers, monitoring systems, caching layers, load balancers, and SEO crawlers — all of which interpret these codes automatically.

Most commonly encountered: 200 OK, 201 Created, 400 Bad Request, 401 Unauthorized, 403 Forbidden, 404 Not Found, 422 Unprocessable Entity, 429 Too Many Requests, and 500 Internal Server Error.

1xx — Informational

CodeNameCommon Use
100ContinueClient should send request body
101Switching ProtocolsWebSocket upgrade handshake
102ProcessingServer processing long operation (WebDAV)

2xx — Success

CodeNameJSON API Use
200OKGET, PUT, PATCH success with response body
201CreatedPOST creates a resource — include Location header
202AcceptedAsync job queued — body contains job ID
204No ContentDELETE success — no response body
206Partial ContentRange requests, file streaming

3xx — Redirection

CodeNameUse
301Moved PermanentlyResource permanently relocated — update links
302FoundTemporary redirect (POST becomes GET)
303See OtherPOST/PUT → redirect to result via GET
304Not ModifiedClient cache is fresh — skip response body
307Temporary RedirectSame method preserved on redirect
308Permanent RedirectSame method preserved, permanent

4xx — Client Errors

CodeNameJSON API Use
400Bad RequestInvalid JSON, missing required fields, validation errors
401UnauthorizedMissing or invalid auth token
403ForbiddenValid token but insufficient permissions
404Not FoundResource doesn't exist
405Method Not AllowedPOST to a GET-only endpoint
409ConflictDuplicate resource, version conflict
410GoneResource permanently deleted
413Content Too LargeRequest body exceeds size limit
415Unsupported Media TypeContent-Type is not application/json
422Unprocessable EntityValid JSON but fails business validation
429Too Many RequestsRate limit exceeded — include Retry-After header

5xx — Server Errors

CodeNameJSON API Use
500Internal Server ErrorUnhandled exception — log and return generic message
501Not ImplementedEndpoint defined but not built yet
502Bad GatewayUpstream service returned invalid response
503Service UnavailableServer overloaded or in maintenance
504Gateway TimeoutUpstream service timed out

REST API Status Code Guide

HTTP MethodSuccess CodeNot FoundValidation Error
GET /resources200 OK404 Not Found400 Bad Request
GET /resources/:id200 OK404 Not Found
POST /resources201 Created400 / 422
PUT /resources/:id200 OK404 Not Found400 / 422
PATCH /resources/:id200 OK404 Not Found400 / 422
DELETE /resources/:id204 No Content404 Not Found

Frequently Asked Questions

401 Unauthorized means the request lacks valid authentication — the client is not identified. 403 Forbidden means the client is identified (authenticated) but does not have permission to access the resource. Think of 401 as 'who are you?' and 403 as 'I know who you are, but you cannot do this.'

Use 400 Bad Request when the request is malformed — invalid JSON syntax, missing required headers, or an unparseable body. Use 422 Unprocessable Entity when the JSON is syntactically valid but fails business validation — for example, a date in the past when a future date is required, or an email that already exists.

Both are temporary redirects. The key difference is method preservation: 302 allows the client to change the method (POST to GET) on redirect, while 307 strictly preserves the original method. Use 307 when you redirect a POST and want the client to re-POST to the new location.

204 is used for successful operations that produce no output — typically DELETE or PATCH when there is nothing meaningful to return. Sending a body with a 204 is technically allowed but ignored by most clients.

A 429 Too Many Requests response should include a Retry-After header indicating when the client can try again. You can specify an absolute date or a number of seconds. Also include rate limit headers (X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset) so clients can manage their request rate proactively.

Related Tools