JSON formatter & validator
Paste JSON to validate it live, pretty-print with your preferred indent, minify for production, or sort object keys alphabetically — all in the browser.
Your JSON never leaves the browser — no upload, no server.
Input
Invalid JSON
Line , column
Options
Indent (format only)
Actions
Output
About this tool
JSON (JavaScript Object Notation) is a lightweight data format used by APIs, config files, and databases. Valid JSON uses double-quoted strings, double-quoted object keys, and strict syntax — no comments, no trailing commas, no single quotes.
Common errors include trailing commas after the last array element or object property, using single quotes instead of double quotes, leaving keys unquoted, and inserting comments (which JSON does not support). This formatter catches those mistakes and points to the line and column when the parser reports a position.
Read more
- Introduction to JSON — the format, data types, and where it's used
- JSON repair — fix fences, trailing commas, and single quotes from an LLM
- JSON diff — added, removed, changed, or moved fields
- JSON to JSON Schema generator — schema from a sample
- JSONL ↔ JSON converter — one record per line
- XML to JSON converter — XML and JSON both ways
- How to parse JSON in Node.js
- How to save a JSON object to a file in Node.js
- The package.json guide — the JSON file every JS project has
Free books, courses, and software
Get my programming books, course editions, and complete software.
Get the download library →