JSON Schema Validator

Validate a JSON document against a JSON Schema and see every violation with its path.

JSON Schema
Loading editor…
JSON Document
Loading editor…
Validation Report
Paste a JSON Schema and a JSON document to validate it against.

Related Tools

Learn more about the JSON Schema Validator

What Does This JSON Schema Validator Do?

A JSON Schema validator checks a real JSON document against a JSON Schema — the same kind of schema produced by our JSON Schema Generator — and reports exactly which fields violate which rules. This is the natural next step after generating or writing a schema: confirm that a real API response, config file, or test fixture actually conforms to it.

This tool uses Ajv, the most widely used JSON Schema validator in the JavaScript ecosystem, and supports both Draft-07 and 2020-12 — it reads the $schema field on your schema and picks the matching engine automatically, defaulting to Draft-07 when the field is missing.

Every violation is reported with a JSON pointer path (e.g. /address/zip) pointing to the exact location in your document, and a human-readable message describing what went wrong — not just the first failure, but every one at once. A malformed schema and a malformed document are treated as separate, clearly labeled error states, so it's always obvious which side of the comparison broke.

Everything runs locally in your browser. Neither your schema nor your document is ever uploaded to a server.

Why Validate Against a Schema?

API Contract Testing

Confirm a real API response matches the documented contract before it reaches consumers or breaks a downstream integration.

CI Validation

Check fixtures, sample payloads, or exported data against a schema as part of a review, without writing custom assertion code.

Debugging Bad Data

When something downstream chokes on a payload, validate it against the expected schema to see precisely which field is the problem.

Schema Review

After writing or generating a schema, run a few known-good and known-bad documents through it to confirm the rules behave the way you intended.

Example

A schema requiring id, name, and email, checked against a document with three separate problems — a wrong type, a missing required field, and a value outside its allowed range.

JSON Schema
{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "type": "object",
  "properties": {
    "id": { "type": "integer" },
    "name": { "type": "string" },
    "email": { "type": "string", "format": "email" },
    "age": { "type": "integer", "minimum": 0 }
  },
  "required": ["id", "name", "email"]
}
Document (3 violations)
{
  "id": "42",
  "name": "Ada Lovelace",
  "age": -5
}

Features

Draft-07 & 2020-12

Detects the draft from your schema's $schema field and validates with the matching Ajv engine.

Full Violation List

Every failing rule is reported, not just the first — each with its JSON pointer path.

Distinct Error States

A broken schema, a broken document, and a failing validation are labeled differently.

Nested Path Reporting

Violations inside nested objects and arrays point to the exact field, e.g. /address/zip.

Fast, Client-Side

Ajv compiles your schema into a validator function, so even large documents stay smooth.

How to use

Paste your input in the left editor. The output appears automatically on the right. Use the toolbar buttons to copy, download, or transform the result.

  1. Paste or type your content in the input editor on the left.
  2. The formatted output is generated automatically.
  3. Use Copy, Download, or other actions from the output toolbar.
  4. Click the expand icon to view the output in fullscreen.
FAQ

Is this JSON Schema validator free?

Yes, it is completely free to use with no limits, signup, or account required.

Is my schema or JSON uploaded to a server?

No. Validation runs entirely in your browser using Ajv, whether you paste or upload files. Neither your schema nor your document ever leaves your machine.

Which JSON Schema drafts are supported?

Draft-07 and 2020-12. The tool reads the $schema field on your schema and validates with the matching Ajv engine automatically, defaulting to Draft-07 if the field is missing.

What does the validation report show?

A pass/fail result, and for a failing document, every violation — not just the first — with its JSON pointer path (e.g. /address/zip) and a human-readable message.

What happens if my schema itself is invalid?

The tool shows a distinct "Invalid Schema" error describing what failed to compile, separate from a document validation failure, so you always know which side of the comparison is broken.

What happens if my JSON document has a syntax error?

It is reported separately as "Invalid Document JSON" with the exact parse error, rather than being treated as a schema violation.

Can I upload files instead of pasting?

Yes. Drag and drop a .json file onto either the schema or document panel, or click the upload icon in the panel header. Files up to 5MB are supported.

Can I copy or download the validation report?

Yes, use the Copy button to copy the full report as JSON, or Download to save it as a validation-report.json file.

Can I validate large documents?

Yes. Ajv compiles your schema into a fast validator function, and evaluation is debounced as you type, so large schemas and documents stay smooth to work with.