JSON formatter

Check JSON, see where it breaks, then format it for reading or minify it.

Free, no sign-up.

JSON formatter

The rules JSON is strict about

Keys and text must be in double quotes; single quotes aren't allowed. There's no comma after the last item in a list or object, and no comments. true, false and null are lowercase. Numbers can't start with extra zeros (007) and can't be NaN or Infinity, and a line break inside text must be written as \n. Code in JavaScript or Python often looks like JSON but breaks one of these rules.

When something is wrong, the message names the first character the parser couldn't make sense of. The real mistake is often just before it, such as a missing comma at the end of the line above.

Format, minify and very large numbers

Formatting and minifying only add or remove spaces and line breaks; the data is the same. Indented JSON is for people reading it, and minified JSON is smaller to send.

This page uses the browser's own JSON parser, which stores numbers the way JavaScript does. Whole numbers above 9,007,199,254,740,991 lose their last digits: {"id":12345678901234567890} comes back as 12345678901234567000. If you work with IDs that long, keep them as strings in quotes.

More developer tools

Paste JSON from an API response, a log or a config file to check it is valid and make it readable. Format indents it two spaces per level; Minify strips the spaces for sending. Invalid JSON gets the parser’s message saying what is wrong and where.

How it works

  • Paste the JSON — Any size your browser can hold.
  • Format or Minify — Format indents it; Minify packs it onto one line.
  • Copy the result — Use the Copy button beside it.

Examples

  • Format — {"name":"Utilava","tools":10} → one key per line, indented
  • Spot an error — A trailing comma or a single-quoted key is reported with its position

FAQ

  • Does it sort keys? — No. Keys keep their order.
  • Does it accept comments? — No. Standard JSON has no comments; remove them first.
  • Is my JSON stored? — No. It runs in your browser; what you paste is never sent anywhere.