JSON · Explainer

What Is JSON Schema Validation?

What is JSON Schema validation?

SHORT ANSWER

JSON Schema validation checks a JSON instance against a schema that describes the expected shape. The schema lists required keys, value types, and bounds, and the validator reports every violation with its JSON Pointer path. The same check runs locally in your browser.

Syntax versus shape

JSON validation has two layers. Syntax asks is this well-formed JSON with correct brackets and commas. Schema validation asks does this valid JSON have the required fields, correct types, and allowed values. An instance can pass syntax and still fail a schema, for example {"name": 42} when name must be a string.

What Lite covers

JSON Schema Lite covers 18 keywords: type, properties, required, additionalProperties, items, enum, const, minimum, maximum, exclusiveMinimum, exclusiveMaximum, multipleOf, minLength, maxLength, minItems, maxItems, minProperties, and maxProperties. It ignores $ref, $defs, allOf, anyOf, oneOf, not, if, then, else, patternProperties, pattern, and format per the Lite contract, which is shown above the Validate button.

Violation paths

Every failure is reported at a JSON Pointer path like /users/2/email. The empty string means the root, /name means the top-level name key, and /users/0/age means the age of the first user in an array. Fix the value at that path and validate again.

Where schemas are used

API request and response contracts, configuration files, and webhook payloads all use schemas to guard against drift. A schema turns an implicit agreement into an explicit contract that both sides can test.

Try it locally

Paste your JSON on the left and your schema on the right, then press Validate. Violations appear with exact paths, and the check runs 100 percent locally without uploading either document.

TRY IT LOCALLY

Try it in your browser with our JSON Schema Lite. No upload, no server.

Open JSON Schema Lite →

FAQ

Is JSON Schema required to use JSON?

No. JSON works without a schema. A schema adds a guardrail when you need to enforce shape, types, and ranges.

Does a passing syntax check mean my data is correct?

No. Syntax only checks brackets and commas. Schema checks whether required keys and types are correct, which syntax cannot see.

What does Lite ignore?

Lite ignores $ref, $defs, allOf, anyOf, oneOf, not, if, then, else, patternProperties, pattern, and format. Those land in v2.0.

Can I validate without uploading?

Yes. Paste both documents and press Validate. The check runs entirely in your browser.