JSON Formatter

Beautify, minify & validate JSON

FreeNo sign-upNothing uploaded
Field guide

About the JSON Formatter

Paste JSON from an API response, a config file or a log and turn it into readable, properly indented JSON. The validator points out syntax errors such as missing commas or quotes, and the minifier strips whitespace for smaller payloads. Everything runs locally, so it is safe for private data.

  1. Paste your JSON into the input box.
  2. Press Beautify to format it or Minify to compress it.
  3. Fix any error that is reported, then copy the output.

Common JSON errors

Trailing commas after the last item, single quotes instead of double quotes, unquoted keys, comments, and NaN or undefined values are all invalid in JSON. The validator points to the line and column of the first error.

Questions

Frequently asked

Is my JSON sent to a server?

No. Formatting and validation happen in your browser using the built-in JSON parser.

Why is my JSON invalid?

Common causes are trailing commas, single quotes instead of double quotes, unquoted keys and comments, none of which are allowed in standard JSON.

What is the difference between beautify and minify?

Beautify adds line breaks and indentation for humans. Minify removes all unnecessary whitespace to make the file as small as possible.