Free tool
JSON Formatter and Validator
Format, validate and minify JSON. Nothing you paste leaves your browser.
Paste JSON below to pretty print it with consistent indentation, collapse it back to a single line, or find out precisely why it will not parse. Everything runs in your browser tab, so nothing is sent to a server.
Malformed JSON is usually one of four things: a trailing comma, a single quote where a double quote belongs, an unescaped character inside a string, or a missing brace. When parsing fails, this tool reports the line and column so you can go straight to it instead of reading the whole payload.
- once it is valid, convert it to CSV for a spreadsheet
- or convert it to YAML, and back
- to compare two payloads, the diff has a JSON mode
How to use it
- Paste or type your JSON into the input on the left.
- Press Format to pretty print it, or Minify to strip every optional space.
- If the JSON is invalid, the error banner names the line and column to fix.
- Copy the result, or press Clear to start again.
Frequently asked questions
Is my JSON uploaded anywhere?
No. The formatting runs entirely in your browser using the built-in JSON parser. The text never leaves your machine, and this page makes no network request when you press Format.
Why does my JSON say invalid when it looks fine?
The four usual causes are a trailing comma after the last item, single quotes instead of double quotes around keys or strings, a literal newline or tab inside a string that needs escaping, and comments, which JSON does not allow. The error message names the line and column.
What is the difference between formatting and minifying?
Formatting adds newlines and indentation so a human can read the structure. Minifying removes every optional character so the payload is as small as possible to transmit. Both describe exactly the same data.
Is there a size limit?
Only your browser tab memory. Since no upload happens there is no server limit, though very large documents will feel slow to render.
The desktop version
JSON Formatter in Toolbelt
This page does the job in a browser tab. Toolbelt is the same tool as a native Mac app, plus the things a web page cannot do.
Tools
{
"name": "Holizmi",
"tools": [
"json",
"jwt",
"base64"
],
"live": true
}{
"sub": "12345",
"name": "Henry",
"exp": 1767225600
}019bd4e2-7a10-7c3e-9f21-4a6b8d3e5c07
019bd4e2-7a11-7b8a-8e44-1c2f9a7d6b13
019bd4e2-7a12-7d5f-b0c9-7e3a1f8c2d95 1 1 one
2 2 two
3 + inserted
3 4 three- Format a whole folder of .json files in one pass
- Convert straight to CSV, YAML, TOML, Go structs or TypeScript interfaces
- Diff two documents side by side with the differences highlighted
- Reformat whatever is on your clipboard with one shortcut