Skip to main content

JSON Schema Validator

Free JSON schema validator: check a JSON document against a schema and see which property broke which rule. Runs in your browser.

JSON Schema

Stays in your browser
{
"type": "object",
"properties": {
"name": {
"type": "string"
},
"age": {
"type": "number",
"minimum": 18
}
},
"required": [
"name",
"age"
]
}

JSON Document

Stays in your browser
{
"name": "Ada Lovelace",
"age": 36
}

Shortcuts: Ctrl+Enter run · Ctrl+Shift+C copy result · / search (use ⌘ on Mac)

Online JSON Schema Validator

Validate a JSON document against a JSON Schema and see exactly which property fails and why. Both inputs stay in your browser — nothing is uploaded. For plain syntax errors use the JSON Parser & Validator; to reformat a document use the JSON Formatter & Beautifier. This JSON schema validator checks a response against a schema without sending it to a server. It helps API developers, QA engineers, and frontend teams confirm that a JSON response follows a documented data contract.

What this validator checks and who uses it

JSON Schema Validator compares a JSON document against a JSON Schema — a separate JSON document describing which properties are required, what type each value should be, and constraints like a minimum number or string length. Two concrete situations: an API team confirming a webhook payload still matches its documented contract after a provider changes their response shape, and a backend developer checking a config file against its schema before deploying it, so a missing or mistyped field is caught locally instead of failing at runtime.

Worked example

With a schema requiring an object with a string name and a number age (minimum 18, both required), validating the document {"name": "Ada", "age": 15} reports exactly one error: $.age: must be at least 18. name passes because it's present and a string; only the age constraint fails, and the path tells you precisely which field to fix instead of comparing the whole document by eye.

Common mistakes and edge cases

  • Confusing "required" with "not empty" — required only checks that the key exists. A required string set to "" or a required number set to 0 still passes unless you also add a minLength, minimum, or pattern constraint.
  • The checker follows the draft named in $schema (2020-12 when there is none). Pick a draft in the list to override it. A $ref to a web address is not loaded; copy that schema into $defs.
  • If the schema and document are in the wrong panels, a hint says so when the document looks like a schema and the schema does not.

Frequently asked questions

Does this validator upload my JSON?
No. The schema and document are parsed and checked in your browser. Nothing is sent to a server or stored.
Which JSON Schema keywords are supported?
All of them for drafts 2020-12, 2019-09 and draft-07, including $ref to $defs, oneOf, anyOf, allOf, if/then/else, patternProperties and format checks such as email, date-time, uri and uuid.
Can the schema point to another file with $ref?
Only inside the same schema (for example #/$defs/address). A reference to a web address is not fetched, because nothing is sent over the network. Paste the other schema into $defs instead.
How are validation errors reported?
Each failure includes a JSON path such as $.user.email or $.items[0], followed by a concise reason. Click an error to jump to that line in the document.
Why does a required field still pass validation if it’s set to an empty string?
Required only checks that the key exists in the document, not that its value is meaningful. Add a minLength, minimum, or pattern constraint if you also need to reject empty or zero values.
How do I validate a JSON response against a schema?
Paste the schema in one panel and the JSON response in the other, then press Validate. Each problem is reported with the path of the property that broke the rule, such as /user/age, and the rule that failed, so you can fix that one field rather than searching the whole document. Both pieces stay in your browser, which makes it safe to check responses that hold real data.

Related tools

More Formatters & Parsers

View all Formatters & Parsers tools →