JSON Schema Library
Start from practical JSON Schema templates, copy valid examples, and open the interactive validator with a schema prefilled.
Validation
4 pagestype JSON Schema Keyword
typeUse type to require a JSON value to be a string, number, integer, boolean, object, array, or null before other rules are evaluated.enum JSON Schema KeywordenumUse enum to allow only one value from a fixed set, such as a status, role, plan name, or integration mode.const JSON Schema KeywordconstUse const when a value must match exactly one JSON value, such as a discriminator, version marker, or fixed feature flag.format JSON Schema KeywordformatUse format to ask validators to check common string shapes such as email, uri, date-time, hostname, uuid, and ip-address.Number
3 pagesminimum JSON Schema Keyword
minimumUse minimum to require a numeric value to be greater than or equal to a lower bound.maximum JSON Schema KeywordmaximumUse maximum to require a numeric value to be less than or equal to an upper bound.multipleOf JSON Schema Keywordmultiple-ofUse multipleOf to require numbers to align to a step size, such as cents, pack sizes, grid units, or batch increments.String
3 pagesminLength JSON Schema Keyword
min-lengthUse minLength to require a string to contain at least a minimum number of Unicode characters.maxLength JSON Schema Keywordmax-lengthUse maxLength to limit a string to a maximum number of Unicode characters.pattern JSON Schema KeywordpatternUse pattern to require a string to match a regular expression, such as an internal code, slug, SKU, or constrained identifier.Array
4 pagesitems JSON Schema Keyword
itemsUse items to define the schema that each element in an array must satisfy.contains JSON Schema KeywordcontainsUse contains when at least one array element must match a nested schema.minItems JSON Schema Keywordmin-itemsUse minItems to require an array to contain at least a minimum number of elements.uniqueItems JSON Schema Keywordunique-itemsUse uniqueItems to reject duplicate JSON values inside an array.Object
3 pagesproperties JSON Schema Keyword
propertiesUse properties to define named fields and their schemas inside a JSON object.required JSON Schema KeywordrequiredUse required to list object properties that must be present.additionalProperties JSON Schema Keywordadditional-propertiesUse additionalProperties to control whether object fields outside properties are allowed.Composition
4 pagesallOf JSON Schema Keyword
all-ofUse allOf when a value must satisfy every schema in a list.anyOf JSON Schema Keywordany-ofUse anyOf when a value may satisfy one or more schemas from a list.oneOf JSON Schema Keywordone-ofUse oneOf when exactly one schema in a list must match.not JSON Schema KeywordnotUse not to reject values that match a schema, such as reserved names, unwanted types, or disallowed structures.