JSON Formatter & Validator
Auto-formats the moment you paste, repairs broken JSON, and shows every error's exact line and column.
Processed 100% in your browser — nothing you enter here is ever uploaded.
Common use cases
Debugging an API response
Paste a minified response straight from your network tab to see nested fields clearly instead of scanning one long line.
Reviewing a config file before committing
Catch a stray comma or missing bracket in a package.json or tsconfig.json before it breaks someone else's build.
Fixing JSON mangled by copy-paste
Text copied from a chat app, log file, PDF or email loses quotes and gains stray commas — the repair pass puts it back together instead of just reporting an error.
Finding one field in a huge payload
Search every key and value in tree view, then copy the JSONPath of the node you found and paste it straight into your code.
How to use the JSON Formatter
Paste or drop your JSON into the left panel — it formats itself as soon as it lands, with no button to press. Nothing you enter leaves your browser.
Broken JSON still gets formatted: trailing commas, single quotes, unquoted keys, comments, NaN and Python-style True/None are repaired automatically, and the status bar lists exactly what was changed.
If it can't be repaired, the error is reported with its line and column and a caret under the offending character — click the location to jump the cursor straight there.
Switch between "Format" and "Minify", pick 2-space, 4-space or tab indentation, and turn on "Sort keys" to order every object alphabetically for clean diffs.
Use "Tree" view to search keys and values across the whole document, collapse branches you don't care about, and copy the JSONPath of any node with one click.
Copy the result, or download it as a .json file — formatted or minified, whichever mode you're in.