JSON formatter, validator and minifier

Paste JSON to format it, shrink it to one line or find out exactly where the syntax is broken.

  • Free, no sign-up
  • Your files and data stay on your device
  • No watermarks or limits

0 bytes uploaded. Everything happens in this tab.

How to use it

  1. Paste your JSON into the box.
  2. Choose format (2 spaces, 4 spaces or tab), minify or sort keys.
  3. Copy the result, or fix the error pointed out in the message.

Example

Input {"name":"Ann","age":30,"tags":["a","b"]}:

{
  "name": "Ann",
  "age": 30,
  "tags": ["a", "b"]
}

About this tool

Responses from an API or a config file often arrive as one unreadable line. Formatting adds indentation so the structure is visible, and validation tells you immediately when a comma, quote or bracket is missing, including the line and column of the problem.

Minifying does the opposite: it removes all unnecessary whitespace so the payload is as small as possible, which helps when you embed JSON in a URL, a test or a script. Sorting keys alphabetically makes two similar objects easier to compare.

Because API responses and configs can contain tokens and customer data, this tool never uploads your input. It is parsed with your browser JSON engine.

Frequently asked questions

Why does my JSON say invalid?

Typical causes are trailing commas, single quotes instead of double quotes, unquoted keys and comments. The message shows the position.

Can it fix JSON automatically?

No, it points to the error so you can correct it. Silent repairs can change meaning.

Does it handle large files?

Yes, within the memory of your browser.

Is the JSON uploaded?

No, everything stays on your device.

Often used next