JSON Formatter
Format, minify and check JSON, with the error pointed at the line.
Runs entirely in your browser. Nothing you enter is uploaded or stored.
Was this tool helpful?
How to use the JSON Formatter
- Paste your JSON.
- Choose an indent, or minify it to a single line.
- If it will not parse, the error message names the line and position to look at.
Questions people ask
Why is my JSON invalid when it looks fine?
Usually a trailing comma after the last item, single quotes instead of double, or a comment. JSON allows none of those, even though JavaScript does.
Is my data sent to a server?
No. Parsing and formatting happen in your browser, which matters when the JSON is a configuration file or an API response with real data in it.
Does it change the order of my keys?
No. Keys stay in the order they appear. Only whitespace changes.