Skip to the tool
GigaJSON

JSON Schema Validator

All tools
Format and check
View and query
Convert
Encode and decode
Sample files
Guides Open GigaJSON

Paste your JSON on the left and a JSON Schema on the right. Every error is listed with the path of the value that fails and the rule it breaks, and the list updates as you type. No schema yet? "Make a schema from this JSON" writes one from your data, the same as the JSON Schema Generator, for you to tighten. To check only that text is valid JSON, use the JSON Validator.

How to use it

  1. Paste or open your JSON, then paste or open the schema.
  2. Read the result: "Valid", or one line per error with the path of the value.
  3. Fix the data or the schema. The result updates as you type.

Private, and made for big files

This tool runs in your browser, in a background worker: nothing you paste or open is uploaded, and nothing is kept after you leave. JSON and XML input can be up to 1 GB, depending on available memory. Processing runs in a background worker; large analyses can take a minute or more. Already loaded features keep working if your connection drops. Loading another tool or jq for the first time needs a connection. When one tool isn't enough, GigaJSON opens your data with a tree, a table, JSONPath/JMESPath/jq queries, transforms, diff and history.

What the errors mean

The messages come from the validator. These are the ones you'll see most, with the schema keyword behind each:

ErrorKeywordFix
Instance type "string" is invalid. Expected "number".typeWrite the value as a number (29, not "29"), or allow both types.
Instance does not have required property "email".requiredAdd the key, or take it out of required.
-5 is less than 0.minimumThe number is outside the range the schema allows.
String does not match pattern.patternThe text doesn't match the regular expression.
String does not match format "email".formatThe text isn't a valid email address (or date, URI…).
Instance does not match any of ["paid","pending","refunded"].enumUse one of the listed values.
Property "note" is not allowed.additionalPropertiesRemove the key, or declare it in properties.

"Load an example" fills both sides with three orders and a schema that catches each of these.

Questions

Which JSON Schema versions are supported?

Draft 4, draft 7, 2019-09 and 2020-12. The schema's $schema keyword picks the version, and a schema without one is read as 2020-12. Validation runs in your browser with the @cfworker/json-schema library.

Are formats like email and date-time checked?

Yes: date, time, date-time, duration, email, hostname, ipv4, ipv6, uri, uri-reference, url, uuid, regex and the JSON Pointer formats. An unknown format name is ignored.

Can the schema reference other files?

Only references inside the same schema, such as "$ref": "#/$defs/address". A $ref to another address isn't downloaded; the result names the reference it couldn't resolve. Copy the other schema into $defs instead.

What does "Property "note" is not allowed" mean?

The schema sets additionalProperties to false, and note isn't listed in its properties. Remove the key from the data, or add it to properties.

How many errors are shown?

All of them, up to the first 1,000. Each error is shown once, at the value that breaks the rule, without the "does not match schema" lines for every object above it.

Is my data uploaded?

No. The tool runs in your browser, in a background worker. Nothing you paste or open goes to a server, and nothing is kept after you leave the page.

All tools