JSON Formatter FAQ
What indentation does this formatter use?
The formatter uses 2-space indentation by default, produced by JSON.stringify(value, null, 2).
Does this tool send data to a server?
No. Formatting runs entirely client-side in your browser.
Example input/output
Input: {"name":"Ada","roles":["admin","user"]}
Output: {
"name": "Ada",
"roles": [
"admin",
"user"
]
}
How it works
This tool parses your JSON input using JSON.parse() and re-serialises it with JSON.stringify(value, null, 2) to produce a consistently indented output. If the input is invalid JSON, the parse error message is shown. Processing runs in your browser.
Common use cases
- Readable-format minified JSON API responses for debugging
- Pretty-print JSON configuration files before committing to version control
- Inspect JSON payloads from browser DevTools in a readable format