JSON to JSON Schema
Paste any JSON sample and get a JSON Schema describing its shape — useful for API documentation, request/response validation, and contract tests.
More options
How to use JSON to JSON Schema
- Paste a JSON object.
- Pick a draft version.
- Toggle examples / all-fields-required.
- Copy the schema — use it with Ajv, JSON Schema validators, or as OpenAPI components.
What is JSON to JSON Schema?
JSON Schema is the standard way to describe and validate JSON. This tool walks your sample and infers type, properties, and required for every level. Strings that look like emails, URLs, or ISO dates get the matching format hint automatically. Choose draft 2020-12, 2019-09, or draft-07 for your $schema URL.
FAQ
- Which drafts are supported?
- 2020-12 (default), 2019-09, and draft-07.
- Are formats detected?
- Yes — email, uri, date, and date-time are detected by regex.
Related tools
People also use
- JSON to CSV📊 CSV Tools
JSON to CSV — Convert any JSON array (of objects or arrays) — or even a single object — into clean CSV. Tick the Flatten option to expand nested objects...
- JSON to TypeScript🗄️ Developer Tools
JSON to TypeScript — Paste a JSON payload and instantly get TypeScript interfaces (or type aliases) describing its shape. Optionally mark all properties...
- JSON to Zod Schema🗄️ Developer Tools
JSON to Zod Schema — Paste JSON and get a ready-to-use <code>z.object({...})</code> Zod schema plus the inferred TypeScript type.
Last updated: