privtools
Developers

JSON Schema Validator

Validate JSON against a JSON Schema online — check types, required fields, formats, and constraints instantly.

100% client-side — your data never leaves this tab

Loading tool…

What is JSON Schema Validator?

JSON Schema Validator checks whether JSON data conforms to a JSON Schema definition — required fields, types, string formats (email, date, URI), numeric ranges, and nested object rules. Paste your schema and data side by side and get instant pass/fail results with path-level error messages. Perfect for API contract testing, config validation, and OpenAPI payload checks. Powered by Ajv, running 100% in your browser.

JSON Schema validation runs entirely in-browser; schema and data are never uploaded.

How to use JSON Schema Validator

  1. 1Paste your JSON Schema in the top editor.
  2. 2Paste the JSON data to validate in the bottom editor.
  3. 3Review results — green for valid, red with error paths for invalid data.
  4. 4Load the sample to see a typical user object schema and valid payload.
  5. 5Fix reported paths like /email or /age based on error messages.

Examples

User schema

Valid: {"email":"a@x.com"} · Invalid: {"email":"not-an-email"}

{"type":"object","required":["email"],"properties":{"email":{"type":"string","format":"email"}}}

API array schema

{"type":"array","items":{"type":"object","required":["id"]}}

Tips & common mistakes

  • Use format: email, date, uri in schemas — common formats are supported via Ajv.
  • Set additionalProperties: false to catch unexpected fields in strict API contracts.
  • Pair with JSON Formatter to prettify schema and data before validating.
  • Validation errors show JSON paths — map them directly to your code or API docs.

Who uses this tool?

  • Backend developers validating API request/response payloads against schemas.
  • QA engineers testing config files and fixture JSON before deployment.
  • Frontend developers checking form data shape before API submission.
  • Students learning JSON Schema syntax with instant feedback.

Frequently asked questions

What is JSON Schema?
JSON Schema is a vocabulary for annotating and validating JSON documents. It defines required fields, types, formats, and constraints that data must satisfy.
Which JSON Schema version is supported?
This tool uses Ajv with common draft features including type, required, properties, format, minimum/maximum, and nested objects.
Can I validate arrays of objects?
Yes. Define type: array with an items schema. Each array element is validated against the items definition.
What do error paths mean?
Paths like /email or /items/0/name point to the exact location in your JSON where validation failed — similar to JSON Pointer notation.
Is my JSON data sent to a server?
No. Schema compilation and validation run entirely in your browser.