JSON formatter

Validate and pretty-print or minify JSON data.

Runs in your browser

Valid JSON. Output is 116 characters.

Output

{
  "name": "TodoEnUnClick",
  "tools": 30,
  "languages": [
    "es",
    "en"
  ],
  "free": true,
  "ads": null
}

What it does: JSON formatter

Turn compact or messy JSON into readable, indented text — or minify it to save space. The JSON is validated before formatting and, if there's an error, you get the line, column and likely cause.

Parsing is done by a dedicated parser that never executes the content and keeps numbers exactly as written, so very large integers don't lose precision.

How to use it

  1. Paste the JSON into the input box.
  2. Choose the indentation or minified output and, optionally, sort the keys.
  3. Copy the result or download it as a .json file.

Examples

API response

Paste a single-line response and get an indented structure that's easy to scan.

Comparing two configs

Format both with “Sort keys” so differences stand out when you compare them line by line.

Limits, formulas and assumptions

  • Maximum size: 5 million characters.
  • Follows the JSON standard (RFC 8259): comments, single quotes and trailing commas are not allowed.
  • Sorting keys changes the order of properties, not their content; array order never changes.
  • Duplicate keys trigger a warning: many JSON readers keep only the last one.

Frequently asked questions

Is it safe to paste private data?

The JSON is processed in your browser and never sent to a server. Still, avoid sharing screenshots that contain tokens or passwords.

How is it different from the JSON validator?

Both validate the same way; the formatter also rewrites the JSON, while the validator shows statistics about its structure.

Why won't it accept my JSON with comments?

Because standard JSON doesn't allow them. Formats like JSON5 or JSONC do, but they aren't valid JSON for most APIs.

Related guides