422 Error

A 422 Unprocessable Entity error is a webserver’s code for:

“I understood your submission format, but the data inside has validation errors.”

A 422 Unprocessable Entity error (defined in WebDAV and widely adopted by modern REST APIs) means the server understands the content type and syntax of the request, but was unable to process the contained instructions due to semantic validation errors.

Unlike a 400 Bad Request error (which usually means syntax is malformed or invalid JSON), a 422 error means your JSON or form data was perfectly formatted, but the values failed business validation rules.

Determining why

  • You submitted a required form field with invalid data (like entering letters in a phone number field, or submitting an email address without an @ sign).
  • A password didn’t meet complexity requirements.
  • You tried to create a record that conflicts with business logic (such as scheduling an appointment on a holiday).

Steps you could possibly take:

  • Inspect the on-screen form errors - Review the form on the page for highlighted input fields or error notifications explaining which fields are incorrect.
  • If you are an API developer:
    • Inspect the JSON response body. Most frameworks (such as Rails, Laravel, Django, FastAPI) return a structured dictionary detailing the specific fields that failed validation.
    • Verify your payload schema against the API documentation.

Source: RFC 9110 Section 15.5.21 (HTTP Semantics)