HTTP Status Codes

Reference for all HTTP status codes

How to Use HTTP Status Codes

  1. 1Search for a code number or keyword
  2. 2Browse by category (2xx, 3xx, etc.)
  3. 3Click any code for full details

About HTTP Status Codes

HTTP Status Codes is a comprehensive reference for all standard and commonly used HTTP response status codes, organized by category. Each code includes a plain-English description, when it is appropriate to use it, and examples of real-world scenarios.

HTTP status codes are the primary mechanism by which servers communicate the result of a request. Every developer working with REST APIs needs to know what 200, 201, 204, 301, 400, 401, 403, 404, 422, 429, and 500 mean.

Search or filter by code number, category (1xx–5xx), or keyword to find any code instantly. All content is statically loaded in your browser — no server requests needed.

Key Features of HTTP Status Codes

  • Complete reference for all standard HTTP status codes (1xx–5xx)
  • Includes non-standard but widely used codes: 418, 429, 451
  • Plain-English description for each code
  • Search by code number or keyword
  • Filter by category: 1xx Informational, 2xx Success, 3xx Redirection, 4xx Client Error, 5xx Server Error
  • Common use cases and examples for each code
  • Works entirely in-browser — no server requests
  • Fast instant-search with no loading delay

Examples

Look up the correct code for a successful resource creation

Find which 2xx code to return from a POST endpoint that creates a new resource.

Input

Search: "created" or code 201

Output

201 Created — Used when a new resource has been created. Include a Location header pointing to the new resource URL.

Find the right error code for a rate-limited API response

Identify the standard code for communicating that a client has exceeded API rate limits.

Input

Search: "rate limit" or code 429

Output

429 Too Many Requests — Include a Retry-After header indicating when the client can retry.

Common Use Cases

  • Looking up the correct status code to return from a REST API endpoint
  • Debugging HTTP errors by understanding what a specific code means
  • Designing error handling in API client code for different response categories
  • Learning HTTP semantics when building or documenting an API
  • Reviewing API designs to check that status codes are used appropriately
  • Quick reference during development without leaving your browser tab

Troubleshooting

Using 200 OK for all responses including errors

Solution

Always use the semantically correct status code. Returning 200 with an error in the body breaks HTTP semantics.

Confusing 401 and 403

Solution

401 Unauthorized means the client is not authenticated. 403 Forbidden means the client is authenticated but lacks permission.

Using 404 for authentication failures

Solution

Returning 404 for protected resources is a security technique to prevent enumeration, but it can confuse legitimate clients. Document your choice clearly.

Frequently Asked Questions

Are all HTTP status codes listed?

Yes. All standard RFC 7231 status codes plus commonly used unofficial codes like 418 (I'm a Teapot), 429 (Too Many Requests), and 451 (Unavailable for Legal Reasons) are included.

What is the difference between 401 and 403?

401 Unauthorized indicates the request requires authentication. 403 Forbidden indicates the server understands the request but refuses to authorize it.

When should I use 200 vs 201 vs 204?

200 OK for successful GET requests, 201 Created for successful POST requests that create a resource, 204 No Content for DELETE or PATCH returning no body.

What does 422 Unprocessable Entity mean?

422 indicates the request was well-formed but semantically incorrect. Common in REST APIs for validation errors.

What is the correct status code for a redirect?

301 Moved Permanently for permanent URL changes, 302 Found for temporary redirects, and 307/308 to preserve the HTTP method during the redirect.

When should I return 503 instead of 500?

500 Internal Server Error indicates an unexpected failure. 503 Service Unavailable indicates the server is temporarily unable to handle requests.

Is my data sent to a server?

No. The status code reference is statically loaded in your browser. No queries or interactions are transmitted.

What does the 1xx status code range mean?

1xx codes are informational — they indicate the request was received and processing is continuing. The most common is 100 Continue.