About the JSON Schema Validator
JSON Schema is a specification for describing the shape, types, and constraints a JSON document should follow — used for validating API payloads, configuration files, and data contracts between systems.
This tool validates a JSON document against a JSON Schema and reports exactly which parts fail validation and why, using the widely-adopted Ajv validation engine.
How it works
- Write or paste your JSON Schema into the schema box.
- Paste the JSON data you want to validate against it into the data box.
- Click Validate to see whether the data conforms to the schema, with detailed error messages for any violations.
Common use cases
- Testing an API contract: Validating a sample request payload against your API's published JSON Schema before writing client integration code.
- Debugging a validation failure: Pinpointing exactly which required field is missing or which type constraint is violated when a schema-validated API call unexpectedly fails.
- Designing a new schema: Iterating on a JSON Schema definition by testing it against several example payloads to make sure it accepts valid data and rejects invalid data as intended.
Frequently asked questions
What JSON Schema draft version does this support?
It uses the Ajv validator, which supports modern JSON Schema drafts including Draft 7 and 2019-09/2020-12 keywords for most common use cases like `type`, `required`, `properties`, `enum`, and format validators.
What does a validation error actually tell me?
Each error identifies the specific path in your data that failed (e.g. which property), the validation keyword that was violated (like `required` or `type`), and a human-readable message explaining the constraint that wasn't met.
Can I validate an array of items against a schema?
Yes — a schema with `"type": "array"` and an `items` schema will validate every element in a JSON array; validation errors will indicate which array index failed.
Why does an obviously-valid document fail validation?
Check for subtle type mismatches (like a number provided as a string), a stricter constraint than expected (such as `additionalProperties: false` rejecting extra fields), or a typo in a required property name in either the schema or the data.
This tool runs entirely in your browser — nothing you enter is sent to a server. Read more in the Privacy Policy, or browse the full list of tools.