Skip to content
4xx Client Error

422 Unprocessable Content

The syntax is fine and the content type is understood, but the data itself fails validation.

What causes it

  • A valid JSON body with a semantically invalid field — an email without an @, an end date before the start date.
  • Rails, Laravel and FastAPI use 422 as the default validation-error status.

How to fix it

  • Return a per-field error map in the body. A bare 422 with no detail is the least useful response an API can give.
  • If the body was not parseable at all, 400 is the more accurate status.

At a glance

Class
4xx Client Error
Reference
RFC 9110 §15.5.21
Standardised
Yes
Retry the request?
No — fix the request

Other 4xx client error codes

Back to the full HTTP status code reference