Skip to main content

HTTP Status Code Explorer

Searchable reference for all HTTP status codes. Click any code to expand real-world use cases, response examples, cacheability, and retry guidance.

✓ All 1xx-5xx codes ✓ Real-world use cases ✓ Cacheable & retryable flags ✓ Response body examples

Frequently Asked Questions

What is the difference between 401 and 403?▼

401 Unauthorized means you are not authenticated — you need to provide credentials (login, API key, JWT). 403 Forbidden means you are authenticated but do not have permission — the server knows who you are but refuses your request. In practice: 401 means log in, 403 means your role lacks the required permissions.

When should I use 422 instead of 400?▼

Use 400 Bad Request for syntactically malformed requests (invalid JSON, wrong content-type, missing required top-level parameter). Use 422 Unprocessable Entity for semantically invalid requests where the structure is valid but the values fail business rules — wrong email format, date in the past, value out of allowed range. Many APIs use 400 for both, but 422 is more precise for validation errors.

What is the difference between 301 and 308?▼

Both are permanent redirects, but 308 Permanent Redirect guarantees the HTTP method is preserved. With 301, browsers may change POST requests to GET on redirect (and many do). With 308, POST stays POST. Same relationship exists for temporary redirects: 302 may change POST to GET, 307 does not.

Should my API return 200 or 204 for DELETE?▼

Use 200 OK if you return a response body (e.g., the deleted resource or a confirmation message). Use 204 No Content if you return nothing. Both are valid — 204 is slightly more semantic but 200 is more common in REST APIs. Never return 200 with an empty body when you could return 204.

How should I handle 429 Too Many Requests?▼

Always include a Retry-After header with the number of seconds until the rate limit resets. Also include X-RateLimit-Limit (total requests allowed), X-RateLimit-Remaining (requests left in window), and X-RateLimit-Reset (Unix timestamp when window resets). Clients should exponential backoff on 429 — retry after Retry-After seconds, doubling on successive failures.

What HTTP status codes are cacheable by default?▼

Cacheable by default (no cache headers needed): 200, 203, 204, 206, 300, 301, 404, 405, 410, 414, 501. Not cacheable by default: 302, 303, 307, 308 (unless Cache-Control is explicitly set). Always cacheable: 200 with Cache-Control or Expires. Override caching with Cache-Control: no-store for sensitive responses.

Share this tool: X / Twitter LinkedIn
✓ 60,000+ developers use DevPlaybook ★★★★★ 4.8 / 5 on Gumroad ✓ MIT licensed · Instant download ✓ No login required

Related Products

on Gumroad

You Might Also Need

More Free Tools

Webhook Tester OpenAPI Validator HTTP Status Code Reference API Request Builder API Response Mock Generator HTTP Status Code Reference WebSocket Tester WebP Converter HTTP Status Code Lookup WebSocket Test Client HTTP Status Code Lookup API Response Time Tester HTTP API Tester HTTP Methods Reference OpenAPI Schema Validator OpenAPI Mock Generator API Test Case Generator Core Web Vitals Guide API Response Formatter & Analyzer HTTP Status Code Reference Web Vitals Scorer Web Vitals Analyzer API Mock Server Config Generator REST API Request Builder API Response Mocker Core Web Vitals Budget Calculator HTTP Headers Analyzer API Rate Limit Calculator HTTP Headers Inspector HTTP Code Snippet Generator PWA Manifest Generator HTTP Mock Response Builder LLM Cost Calculator Caddy Caddyfile Generator HTTP Cache-Control Builder WASM Module Explorer HTTP Header Analyzer AI Prompt Cost Calculator HTTP/2 Server Push Headers Builder Lighthouse Score Simulator Mock Service Worker (MSW) API Mocking Guide Core Web Vitals Calculator HTTP Security Headers Checker LLM Prompt Cost Calculator AI Rate Limit Calculator WebAssembly Binary Inspector Web Vitals Budget Planner HTTP Cache Header Builder Web Performance Checklist Image Optimizer Checklist API Key Generator AI Doc Generator — Pro Tool Color Blindness Simulator curl Command Builder HTTP Security Headers Generator JSON Diff Viewer JSON Diff JWT Builder JWT Decoder Developer Utilities Rate Limiter Tester API Changelog Generator Service Worker Generator HMAC Generator CSP Header Builder Rate Limit Calculator CORS Policy Builder Haproxy Config Validator WCAG Contrast Checker HAR Diff Analyzer JWT Debugger Pro Vue Component Generator LLM Context Window Calculator LLM Token Counter Bundle Size Estimator SSL Certificate Checker Prompt Token Estimator nginx Config Builder Pulumi Modern IaC Guide Bundle Size Impact Calculator HTML5 Canvas API Playground Token Context Calculator OpenAI Function Calling Generator TTFB Analyzer Token Counter & Cost Estimator AI API Rate Limit Calculator JWT Decoder & Validator

Enjoying this tool? Get more like it.

Weekly developer tool guides, productivity playbooks & AI tricks. Free. No spam.

DevPlaybook Pro 7 days free

Unlock AI-Powered Dev Tools

  • ⚡ AI Code Review, Doc Generator & SQL Builder
  • ⚡ All premium templates & early access
  • ⚡ Member discounts on Gumroad products
Start Free Trial →

$9/mo after trial · Cancel anytime

Want the full toolkit?

Get DevPlaybook Pro

Every template, guide, boilerplate, and automation script in one bundle. 13 premium products — grab them all at once and save big.

$79
$241 separately Save $162 (67% off)
Get DevPlaybook Pro — $79 →

MIT licensed · Instant download · No subscription

See what's included → Browse all deals →