Caspian Office

JSON formatter & validator

Paste JSON and pretty-print it with the indent you choose, minify it to a single line, or validate it with a clear error message pointing at the problem. Everything runs in your browser.

Open JSON formatter & validator →
Private · runs in your browserOffline · after first loadFree · no signup

What is the JSON formatter & validator?

A tool that pretty-prints messy JSON, minifies it to a single line, or validates it with a clear error message that points at the problem. Paste your JSON and it checks it as you type. Everything runs in your browser, so your data is never uploaded and it works offline.

How to use JSON formatter & validator

  1. Paste your JSON — Drop your JSON text into the editor. It is validated live as you type, and the status shows whether it is valid.
  2. Choose an indent — Pick 2 spaces, 4 spaces or a tab from the Indent menu to set how the formatted output is laid out.
  3. Format or minify — Click Format to pretty-print it with your chosen indent, or Minify to collapse it onto one line with no extra whitespace.
  4. Copy or clear — Use the Copy action in the header to grab the result, or Clear to empty the editor and start again.

Frequently asked questions

Is my JSON sent to a server?

No. Parsing, formatting and validation all happen in your browser, so your data never leaves your device and the tool works offline.

What happens if my JSON is invalid?

The status shows 'Invalid JSON' and an error message is displayed, including the line and column of the problem where the browser reports a position.

What's the difference between Format and Minify?

Format adds indentation and line breaks for easy reading, while Minify strips all unnecessary whitespace to produce the smallest single-line version.

Can I change the indentation?

Yes. The Indent menu lets you format with 2 spaces, 4 spaces or a tab character.

Tips

Related tools

← Browse all Caspian Office tools