Skip to content
SUMILORASUMILORA

JSON formatter and validator

Developer tools

Paste JSON. It is formatted as you type, and if it will not parse you get told where and probably why.

Runs in your browser

Nothing is uploaded. The work happens on your own device, so your file or text never reaches us.

About this tool

Errors that are actually useful

Unexpected token } in JSON at position 1472 is not help when the JSON is one minified line.

So a failure here reports the line and column, shows the text around it, and names the likely cause when the shape of the input gives it away:

  • a trailing comma before a closing bracket, which JavaScript allows and JSON does not
  • single quotes, which are JavaScript strings and not JSON ones
  • True, None, NaN or undefined — Python or JavaScript literals rather than JSON’s lowercase true, false and null
  • comments, which JSON5 and JSONC allow and strict JSON does not

It never leaves your browser

JSON you are debugging tends to contain tokens, keys, customer records and internal hostnames. Pasting that into a site that posts it to a server is a data leak, however the site is worded.

This one parses in your browser. There is no request to inspect, because there is no request.

Questions

Why is my JSON invalid when it looks fine?

Usually a trailing comma, single quotes instead of double, or a Python literal like True. The error message above names which of those it found.

Does JSON allow comments?

No. JSON5 and JSONC do, and many tools accept them, but a strict parser will reject them. Strip them before using the file as JSON.

Is my JSON uploaded?

No. It is parsed and formatted entirely in your browser, so the tokens, keys and customer records that debugging JSON usually contains never leave your device.

Related tools