How to use
- 1Paste your JSON (a sample is pre-filled to try).
- 2Format with 2 spaces, 4 spaces or tabs, or minify to one line.
- 3Fix any error using the reported line and column.
- 4Optionally sort keys, browse the collapsible tree, convert arrays to CSV, then copy or download.
The most common JSON errors
JSON (RFC 8259) is stricter than JavaScript. The usual culprits: trailing commas after the last item, single quotes instead of double quotes, unquoted keys, comments (// and /* */ are not allowed), NaN, Infinity or undefined as values, and unescaped control characters or line breaks inside strings. The validator reports the line and column of the first error so you can jump straight to it.
Format, minify, sort and convert
Formatting with indentation makes API responses and config files readable; minifying removes all whitespace for smaller payloads. Sorting keys alphabetically makes two JSON documents easy to diff. The tree view lets you collapse large nested objects to navigate them. JSON → CSV turns an array of objects into a spreadsheet-ready table, using the object keys as column headers.
Your data stays in your browser
Parsing and formatting happen locally in JavaScript, so it is safe to paste API responses that contain tokens, customer records or internal data — nothing is sent to a server or logged.
Frequently asked questions
How do I validate JSON?
Paste it in. Valid JSON formats instantly; invalid JSON shows an error with the line and column of the problem.
Why is my JSON invalid when it works in JavaScript?
JavaScript object literals allow single quotes, unquoted keys, trailing commas and comments. JSON allows none of these.
Can I convert nested JSON to CSV?
CSV conversion works for arrays of objects. Nested objects or arrays inside values are kept as JSON text in the cell, since CSV is flat.
Is there a size limit?
No fixed limit; it depends on your browser. Multi-megabyte files work, but very large files may make the tree view slow.
Not happy with the results?
Talk to Webin Agency about fast, SEO-friendly websites, e-commerce and Google Ads management.