JSON Schema Validator
Validate JSON data against JSON Schema definitions. Get detailed error reports with paths. All processing done in your browser.
JSON data is valid against the provided schema!
| Path | Error |
|---|
How to Use JSON Schema Validator
Enter Schema
Define your JSON Schema that describes the expected structure.
Enter Data
Paste the JSON data you want to validate against the schema.
Validate
Click Validate and review the results for any errors.
What is JSON Schema?
JSON Schema is a vocabulary that allows you to annotate and validate JSON documents. It provides a contract for what JSON data is required for a given application and how to interact with it. JSON Schema is used for validation, documentation, and generating mock data.
Key Features
Type Validation
Validate types: string, number, integer, boolean, array, object, null
Constraints
Min/max length, range, pattern, required fields, and more
Structure Definition
Define nested objects, arrays, and complex data structures
Frequently Asked Questions
This tool supports JSON Schema Draft-07, Draft 2019-09, and Draft 2020-12 through the Ajv library. Most common schema features are supported.
Yes! JSON Schema supports deeply nested objects and arrays. You can define properties and items at any level of nesting, with individual validation rules for each field.
The tool first validates that your schema itself is valid JSON Schema. If the schema has errors, those will be reported before attempting to validate the data.
type (string, number, object, array, boolean, null), properties with nested schemas, required listing mandatory keys, enum for fixed value sets, pattern for regex-constrained strings, and the range checks minimum/maximum and minLength/maxLength. additionalProperties: false tightens objects against extra keys. Together they cover the bulk of API validation rules.
In modern JSON Schema, format is an annotation by default, not an automatic assertion - validators enforce it only when configured to, which the 2020-12 spec made explicit with a separate format-assertion vocabulary. Use pattern or a custom keyword when enforcement must be guaranteed, and treat format as interoperability metadata otherwise.
$ref pointing at #/$defs/address references a schema fragment under $defs and validates against it wherever used - the deduplication mechanism. Draft 2020-12 renamed the older definitions to $defs and formalized $dynamicRef for recursive structures like comment trees. References can also point at external documents, though bundling locally is more common.
allOf requires every subschema to validate - an intersection, used to compose a base schema with extra constraints. anyOf requires at least one - a union, used for polymorphic payloads. oneOf requires exactly one; validating two or zero subschemas fails, which is stricter than people expect and the usual cause of surprising errors with overlapping schemas.
2020-12 split the specification into separately-negotiable vocabularies (validation, annotation, format-assertion), renamed definitions to $defs, simplified exclusiveMinimum to a plain number, and replaced the older items keyword with prefixItems plus items. Most tooling supports both; draft-07 remains the most widely deployed, but 2020-12 is the current published standard.
Related Tools
Authoritative References
Primary sources behind this tool - official standards and specifications, not secondhand summaries.
JSON Schema - 2020-12 Validation Specification
The JSON Schema 2020-12 validation specification — the current published standard.
JSON Schema - Learn
The official learning site for JSON Schema, from basics to $ref and $defs.
JSON Schema - Wikipedia
What JSON Schema validates, and its role in API contracts and config validation.