JSON Formatter & Validator
Paste raw JSON to make it readable, check that it is valid, or compress it into one line.
Use the JSON Formatter & Validator
About the JSON Formatter & Validator
JSON is the standard format for APIs, configuration files and data exchange, but minified or hand-edited JSON is hard to read. This formatter re-indents your data with two spaces so nested objects and arrays are easy to follow.
The validator reports the parser's error message when something is wrong, such as a trailing comma, a missing quote or an unclosed bracket. Use Minify when you need the smallest possible payload. Your data never leaves your device.
How to use this tool
- Paste your JSON into the input box.
- Click Format to beautify it or Minify to compress it.
- If the JSON is invalid, read the error message and fix the issue.
- Click Copy to copy the result.
Frequently asked questions
What makes JSON invalid?
- Common causes are trailing commas, single quotes instead of double quotes, unquoted keys and missing brackets.
Is my JSON sent to a server?
- No. Parsing and formatting happen locally in your browser.
What is the difference between format and minify?
- Format adds indentation for readability. Minify removes all unnecessary whitespace to reduce size.