JSON Formatter

Beautify and validate JSON in your browser.

FreeNo accountOn your device

Runs in your browser. How to verify

Loading tool…

About this tool

Paste JSON to format it with indentation, validate it, or minify it. If it is invalid, you get the line, the column and the usual cause.

How to use

1
Step 1
Paste your JSON.
2
Step 2
Choose Format, Validate or Minify.
3
Step 3
Press Run, then copy or download the result.

How it works

Valid JSON uses double quotes, no trailing commas and no comments. When parsing fails, the tool points at the first character that cannot be valid.

Worked example

A trailing comma

Input
{"tags": ["a", "b",]}
Output
Line 1, column 20: Trailing comma before a closing bracket
Walkthrough
Remove the last comma and it formats cleanly.

Limitations

  • Strict JSON only: comments and single quotes are rejected.

Questions

Why is my JSON invalid?
The usual causes are trailing commas, single quotes, unquoted keys, comments and NaN or undefined values.
Is my JSON uploaded?
No. Parsing happens in your browser.

Features

  • Format, validate, minify
  • Line and column errors
  • Private

Guides

Related resources

Guides and videos from around the web—opens on YouTube or the publisher’s site.

  • What Is A RESTful API?

    Traversy Media

    Most APIs exchange JSON—context for pretty-print and schema checks.

    Watch on YouTube
  • Inspect Network Activity - Chrome DevTools 101

    Chrome for Developers

    Debugging payloads you paste into JSON and JWT tools.

    Watch on YouTube