JSON Schema Generator
Paste a sample JSON payload — get a valid, ready-to-use JSON Schema with inferred types, format detection, and required fields.
How type inference works
The generator walks your sample recursively. Each value becomes a schema node: string, integer, number, boolean, null, object, or array. Nested objects and arrays are expanded in full. When an array mixes item shapes, the item schema uses anyOf; when every item is an object, their properties are merged and only keys present in all items stay required.
Format detection
With format detection on, string values are tested against common patterns and annotated: ISO 8601 timestamps get format: "date-time", plain dates get "date", and emails, URLs, UUIDs, and IPv4 addresses get their matching formats. This turns a hand-written schema you would have typed for ten minutes into a one-click starting point you can drop into Ajv, Python jsonschema, or an OpenAPI components/schemas section.
FAQ
What is JSON Schema?
How does the generator infer types from my sample?
format keyword, and every non-null property is marked required unless you turn that off.Draft 2020-12 vs Draft-07 — which should I pick?
$schema identifier differs.