Utilumo
LightDarkSystem
Guide1 min readUpdated July 1, 2026

How to format (pretty-print) JSON

Short answer

Paste the JSON into a formatter and it re-indents the structure with consistent spacing so it is readable. Formatting also reveals syntax errors, since invalid JSON cannot be parsed and re-printed.

What formatting does

Pretty-printing parses JSON and re-serializes it with newlines and indentation, so nested objects and arrays line up. It does not change the data — only the whitespace. Minifying is the reverse: it removes that whitespace to shrink the payload. See what is JSON.

{"id":1,"tags":["a","b"],"ok":true}

{
  "id": 1,
  "tags": ["a", "b"],
  "ok": true
}
Before (minified) and after (formatted)

Format your JSON

  1. Paste the JSONDrop minified or messy JSON into the formatter.
  2. Read the formatted outputIndentation makes the structure and nesting obvious.
  3. Fix any errorIf it will not format, an error points to the invalid spot — often a trailing comma or unquoted key.
  4. Copy or minifyCopy the clean version, or minify it again for production.
Try it: JSON FormatterFormat, validate, and minify JSON locally — nothing is uploaded.Open tool
Formatting is also validationA formatter must parse the JSON first, so if it succeeds your JSON is syntactically valid. A failure usually means a trailing comma, a missing quote, or a stray bracket.

Common JSON syntax errors

  • Trailing commas after the last item — not allowed in JSON
  • Single quotes instead of double quotes around strings and keys
  • Unquoted object keys (id: instead of "id":)
  • Comments — standard JSON does not allow them

References

Questions

Does formatting JSON change the data?

No. Pretty-printing only adds whitespace and indentation. The keys, values, and structure stay identical, so the parsed result is the same.

What is the difference between formatting and minifying?

Formatting adds indentation and newlines to make JSON readable. Minifying removes all optional whitespace to make the payload as small as possible for transfer. They are opposites of the same data.

Does this send my data anywhere?

No. Utilumo's developer tools parse and transform input inside the browser tab. Nothing is uploaded, stored, or logged.

Keep reading