JSON Formatter, Validator & Tree Viewer
Paste raw JSON to validate it, pretty-print or minify it, and browse the structure as a collapsible tree.
Validation and formatting rules
This tool runs your input through the browser's native JSON parser, which follows the strict JSON specification (RFC 8259) — not the more permissive rules of a JavaScript object literal. Formatting re-serializes the parsed result with two-space indentation; minifying re-serializes it with none.
A common trailing-comma error
Pasting an object where the last property ends with a comma — such as a "tags" array followed immediately by a closing brace with an extra comma before it — is one of the most frequent parse failures developers hit when hand-editing config files. Removing the trailing comma before the closing bracket resolves it immediately; the tool will point at the exact line and column so you don't have to scan the whole file to find it.
Common questions
No. Parsing, validation, and formatting all run locally in your browser using the built-in JSON engine — nothing you paste is sent to a server, which makes this safe to use with real API responses or config files that contain sensitive data.