JSON Formatter & Validator
Pretty-print, minify and validate JSON, with the line and column of the first error.
Runs entirely in your browser. Nothing you enter is uploaded.
How to use
- Paste your JSON into the input box.
- Press Format to pretty-print it, or Minify to compress it.
- If the JSON is invalid, the error message shows the line and column.
- Copy the result or download it as a file.
Example
{"name":"Ada","skills":["PHP","SEO"]} becomes a neatly indented block you can read at a glance.
About this tool
Everything runs in your browser. The validator follows the JSON standard strictly, so trailing commas, single quotes and comments are reported as errors.
Frequently asked questions
Is my JSON sent anywhere?
No. It is parsed in your browser and never leaves your device.
Why does a trailing comma fail?
Standard JSON does not allow trailing commas, comments or single-quoted strings. The error shows where the problem is.
Can I sort the keys?
Yes. Tick "Sort keys" before pressing Format.
Related tools
Base64 Encoder & DecoderEncode text to Base64 or decode it back, with a URL-safe option.In browserURL Encoder & DecoderEncode or decode URLs and query strings, and see the query parameters in a table.In browserText Compare (Diff)Compare two pieces of text and see added and removed lines highlighted.In browser