JSON formatter

Pretty-print, validate and minify JSON.

Mode
Indent

0 lines · 0 characters

0 lines · 0 characters

Results update as you type.

Runs in your browser. Nothing uploaded.

How to format JSON

  1. Paste your JSON into Input.
  2. Choose Format to pretty-print it or Minify to strip whitespace. Pick an indent and optionally sort keys.
  3. If the JSON is invalid, the status line shows the line, column and reason. Click Show me to jump to it, or turn on Fix mistakes to repair it.

Format vs. minify

Formatting (also called beautifying or pretty-printing) adds line breaks and indentation so JSON is easy to read and review. Minifying removes all optional whitespace to make it as small as possible for sending over a network or storing.

Both also validate your JSON, so they double as a quick JSON checker.