JSON formatter & validator
Format, minify and validate JSON, with the exact line and column of any error.
Related tools
JSON formatter & validator
Paste JSON and this tool reformats it into something readable — or tells you exactly where it breaks. It is the everyday companion for API responses, config files, log payloads, package manifests and the minified blob you just copied out of a network tab.
Indentation is up to you: two spaces, four spaces, or tabs. Choose "Minify" instead and every optional space and newline is stripped, which is what you want before pasting a payload into a query string, an environment variable or a test fixture. Turn on "Sort object keys alphabetically" and every object in the document is reordered recursively, top level and nested alike. That makes two versions of the same config comparable in a diff, since key order stops being noise.
Validation runs on the same pass. When the input is not valid JSON you get a calm message naming the line and column of the problem alongside the parser's own reason, so a trailing comma or a missing quote takes seconds to find rather than minutes of squinting. When the input is valid, the tally confirms it and adds the numbers worth knowing: how many keys the document contains counted recursively, how deeply it nests, and how many bytes the formatted output takes.
Everything runs in your browser — no request is made and nothing is logged. That matters for JSON in particular, because payloads so often carry tokens, customer records or internal hostnames. Paste production data here without a second thought, then copy the result or download it as a file.