JSON Formatter

Format, validate and minify JSON in your browser. Nothing is uploaded.

Input

0 chars
Runs in your browser
Output
 
Top-level keys
—
Max depth
—

Formula & explanation

Paste any JSON and get a readable, indented version. The tool validates the syntax and points to the error if the JSON is invalid.

Choose Minified to remove whitespace and get the smallest possible output.

Example

Indentation2
Output size0 KB
Top-level keys3

Frequently asked questions

Is my JSON sent to a server?

No. Parsing and formatting happen entirely in your browser.

Why does it say invalid JSON?

Common causes: trailing commas, single quotes instead of double quotes, or unquoted keys.

Does it keep the key order?

Yes, unless you enable 'Sort keys alphabetically'.

Related tools