Overview
Beautifies or minifies JSON in your browser as you type, with two-space or four-space indentation, the browser's own RFC 8259 parser for validation, and copy plus download of the result — nothing is uploaded to any server.
How It Works
Paste or type JSON and it reformats live at two-space indent. The Indent 4 Spaces button re-serialises with wider indentation, Minify JSON collapses the document to one compact line, and Clear resets the editor. When the input is malformed, a red panel shows the browser parser's own error message with a hint about the usual culprits — double quotes and trailing commas.
Step-by-Step Usage Guide
- Paste your raw JSON string or API response into the editor.
- Choose Indent 2 Spaces, Indent 4 Spaces, or Minify JSON.
- Fix any syntax error using the red panel's message and hint.
- Copy the result or download it as a .json file.
Technical Specifications & Standards
Validation and formatting both go through the runtime's native JSON.parse() and JSON.stringify(), so the tool is exactly as strict as production servers: comments, trailing commas, and unquoted keys are errors, not warnings to be tolerated. The download button emits the currently formatted document as a .json file. The site also ships a service worker (production builds) that caches the application shell and bundles after your first visit, so the formatter keeps working offline on later visits.
Targeted Use Cases
- Pretty-printing raw REST or GraphQL responses before reading or committing them.
- Minifying configuration payloads for embedding in environment variables or single-line storage.
- Confirming a payload is strictly valid before a strict parser on the server sees it.
- Producing consistently indented JSON so version-control diffs show real changes only.
Notes & Gotchas
- Indentation is fixed to 2 or 4 spaces — there is no tab option and no key-sorting mode.
- Error output is the browser's own message (which points at a character position inside its text), not a formatted line-and-column readout — use the position in the message plus the hint panel to locate the fault.
- Strictness is deliberate: JSON5 conveniences like comments and trailing commas are rejected because real production parsers reject them too.
- Offline use needs a prior visit — the service worker caches assets after the first load, so a cold first visit still requires the network.
Frequently Asked Questions
Is my JSON sent to an external server?
No. Parsing and formatting run entirely in your browser with native JSON functions.
How large a document can it handle?
As large as your browser tab's memory allows — multi-megabyte payloads format in well under a second on a typical machine.
Does it support comments or trailing commas?
No, by design. The tool enforces strict RFC 8259 JSON, the same dialect production parsers accept.
Does it work offline?
Yes, after your first visit — the service worker caches the app shell and code bundles. The very first load needs the network.