JSON Formatter & Validator
Validate, prettify, minify or sort keys. Invalid JSON gets a specific error rather than a silent failure.
"name": "Alice",
"scores": [95, 87, 91],
"active": true
}
The errors you will actually hit
Nearly every JSON parse failure is one of four things: a trailing comma after the last item, single quotes where double quotes are required, an unescaped double quote inside a string, or a stray control character pasted in from a terminal. JSON has no comments and no trailing commas — both are legal in JavaScript, which is why hand-edited config files break so reliably.
API responses are not safe to paste anywhere
The JSON people most often need to format is a captured API response, and those routinely carry bearer tokens in headers, customer records in the body, and internal hostnames in the metadata. A formatter that round-trips through a server puts all of it into someone else's logs. This one parses with the browser's own JSON.parse and re-serialises in the page, so a production payload stays on your machine.
Common questions
Why does my JSON fail to parse?
Most often a trailing comma, single instead of double quotes, an unescaped quote inside a string, or comments — which JSON does not allow.
What does Sort Keys do?
Reorders object keys alphabetically, which makes two payloads far easier to diff against each other.
Is my payload sent to a server?
No. Parsing and formatting use the browser's built-in JSON functions and run entirely in the page.