ToolsForWeb

Saved

Tap ☆ on any tool to keep it here.

toolsforweb

JSON Schema Validator

Validate a JSON document against a Draft 2020-12 schema, with precise paths for every issue.

Runs in your browser — nothing is uploaded

Loading tool…

Results are provided as is, for general information. Check anything important before relying on it. See the Terms of Use.

About this tool

JSON Schema describes the structure and constraints of JSON data: which properties are required, what types and formats values use, and how nested objects or arrays are shaped. Paste a Draft 2020-12 schema beside a JSON document and this tool reports every mismatch with both the document path and the rule that failed. Validation runs in your browser. Local references such as #/$defs/address resolve inside the pasted schema; external references are rejected rather than fetched.

When to use it

Checking an API request or response against its documented contract before debugging application code.
Testing required fields, numeric limits, string formats and nested structures while designing a schema.
Finding every validation failure at once instead of fixing one error per run.
Verifying local $defs and $ref links before committing a schema to a repository.

Questions

Which JSON Schema version does this tool support?

Draft 2020-12. Put https://json-schema.org/draft/2020-12/schema in $schema when you want the document to declare that dialect explicitly. Older schemas often work when they use shared keywords, but draft-specific behavior should be tested with a validator for that draft.

What is the difference between invalid JSON and a schema validation failure?

Invalid JSON cannot be parsed at all — common causes are trailing commas, comments, single quotes or missing braces. A validation failure is valid JSON that does not satisfy a valid schema, such as a missing required property or a string where an integer is required. The tool identifies which editor has a syntax error before applying schema rules.

Can I use $ref and $defs?

Yes, for references inside the same pasted schema. Define reusable schemas under $defs and point to them with a fragment such as #/$defs/address. Relative files and https URLs are external references and are deliberately blocked, because following them would send information to another server and make validation depend on the network.

Why does each error show two paths?

The document path points to the value that failed, such as /users/2/email. The schema path points to the rule that rejected it, such as #/properties/users/items/properties/email/format. Together they tell you whether to fix the data or the contract.

Does format validate email addresses and dates?

Yes. Common Draft 2020-12 string formats such as email, date, date-time, hostname, IPv4, IPv6 and URI are checked. A format check verifies syntax, not existence: a well-formed email address can still have no mailbox, and a well-formed URI can still return an error.

Is my schema or document uploaded?

No. Parsing, schema compilation and validation all happen in your browser. The tool makes no validation request and refuses external $ref values, so a pasted schema cannot cause it to retrieve another URL.

Related tools