HTTP 4xx Client Error Codes List

Get a complete, ordered reference of HTTP 4xx status codes for client-side request errors.

HTTP 4xx client error codes(29 registered status codes)

Based on the IANA HTTP Status Code Registry for the 4xx range. Includes any registered special entries and excludes unassigned ranges.

How to use this list

Apply HTTP 4xx codes in 3 steps

Takes ~5 seconds
  1. 1
    Choose output format

    Select text for docs, JSON for constants, or HTML for form controls.

  2. 2
    Copy or download

    Use one-click copy or download the output file.

  3. 3
    Use in your workflow

    Paste into runbooks, tests, SDK docs, or monitoring rules.

Need dropdown options for 4xx handling? Use HTML <select> output.

Common use cases

  • Developers documenting expected API response classes
  • QA teams creating focused response-code test coverage
  • Platform teams standardizing logs and alert labels

Examples

4xx example code.

Input
404
Output
404 Not Found

Additional code in the same class.

Input
429
Output
429 Too Many Requests

HTML output for select menus.

Input
404 Not Found
Output
<option value="404 Not Found">404 Not Found</option>

Reliable HTTP 4xx response reference

This list provides a focused reference of HTTP 4xx entries so teams can standardize behavior across implementation, testing, and operations.

HTTP 4xx codes all mean the client's request is the problem, but they're not interchangeable: 401 signals missing or invalid credentials, 403 means the caller is authenticated but not authorized, 422 flags a well-formed request that fails validation, and 429 tells the client to back off and retry later. This list gives you the full IANA-registered 4xx range in copy-ready text, JSON, or HTML <option> format, so error-handling code, validation messages, and API docs map to the correct code instead of returning a generic 400 for everything.

401 vs. 403, sorted out

The 4xx range covers everything from missing auth to malformed syntax to rate limiting — this list keeps the distinctions straight.

  • 401 for missing/invalid credentials
  • 403 for valid credentials, no permission
  • 429 for rate-limited requests
One click, three formats

Grab the range as plain text, a JSON array, or ready-to-paste HTML <option> tags.

  • Plain text list
  • JSON array
  • HTML <option> tags
Scoped to client errors only

No success or server-side codes mixed in — just the range that means the request itself needs fixing.

  • Error-handling UI copy
  • Validation and auth test fixtures
  • API error documentation

Choosing the right 4xx code

Precise 4xx codes let API clients handle failures programmatically instead of just showing a generic error.

  • Use 401 for missing or invalid credentials and 403 for valid credentials without permission — don't conflate the two.
  • Return 429 with a Retry-After header when rate limiting, so well-behaved clients back off automatically.
  • Reserve 422 for syntactically valid requests that fail business validation, and 400 for requests that are malformed.

Frequently asked questions

What's the difference between 401 and 403?>
401 means the request has no valid credentials, or the wrong ones. 403 means the credentials were valid, but the authenticated user isn't allowed to perform this action.
Should a failed form validation return 400 or 422?>
Use 422 when the request is syntactically correct but fails semantic validation, like an out-of-range value. Use 400 when the request itself is malformed, such as invalid JSON.
What does 429 mean and how should a client respond?>
429 means the client has sent too many requests in a given time window. Clients should read any Retry-After header and back off before retrying, rather than retrying immediately.

Related Developer lists

Application MIME Types List | Copy-Ready Text, JSON & HTML

Copy common application/* MIME types in text, JSON, or HTML format for API content negotiation, downloads, and file validation.

Audio MIME Types List | Copy-Ready Text, JSON & HTML

Copy common audio MIME types in text, JSON, or HTML format for uploads, playback support checks, and processing pipelines.

Common MIME Types List | Copy-Ready Text, JSON & HTML

Copy a practical common MIME types list in text, JSON, or HTML format for uploads, APIs, validation, and content handling.

HTTP 2xx Success Codes List | Copy-Ready Text, JSON & HTML

Copy all HTTP 2xx success codes in text, JSON, or HTML format for API docs, tests, and monitoring workflows, ready to paste.

HTTP 3xx Redirect Codes List | Copy-Ready Text, JSON & HTML

Copy all HTTP 3xx redirect codes in text, JSON, or HTML format for API docs, tests, and monitoring workflows, ready to paste.

HTTP 5xx Error Codes List | Copy-Ready Text, JSON & HTML

Copy all HTTP 5xx server error codes in text, JSON, or HTML format for API docs, tests, and monitoring workflows.

HTTP Request Methods List | Copy-Ready Text, JSON & HTML

Copy a clean http request methods list (GET, POST, PUT, PATCH, DELETE, HEAD, OPTIONS, TRACE, CONNECT) in text, JSON, or HTML for API docs and tooling.

HTTP Status Codes List | Copy-Ready Text, JSON & HTML

Copy the complete IANA-registered HTTP status codes list in text, JSON, or HTML format for APIs, docs, testing, and observability workflows.

Image MIME Types List | Copy-Ready Text, JSON & HTML

Copy common image MIME types in text, JSON, or HTML format for upload validation, image processing, and media tooling.

Video MIME Types List | Copy-Ready Text, JSON & HTML

Copy common video MIME types in text, JSON, or HTML format for upload policies, streaming workflows, and player support checks.