JSON Formatter & Validator

Format, validate and minify JSON in your browser. Errors are shown with the exact line and a plain-English fix, and you can browse the data as a tree or turn it into CSV.

  • 100% free
  • No sign-up
  • Runs in your browser

Paste your JSON

Output
Indent

Checks as you type. Large numbers and key order are kept exactly as written.

Result

Your formatted JSON, errors and stats will appear here. Paste some JSON or try the example.

About the tool

How the JSON Formatter & Validator works

The JSON Formatter & Validator makes JSON easy to read and quick to fix. Paste JSON or drop a .json file and it checks it as you type. Valid JSON is shown neatly indented and colour-coded; invalid JSON shows the exact line and column of the problem with a clear explanation, such as a missing comma or a property name that needs quotes.

Many errors come from copying JavaScript objects or config files. The Fix errors button repairs the common ones automatically: trailing commas, comments, single quotes, unquoted keys and Python-style True, False and None.

You can minify JSON for production, sort keys alphabetically, explore large files in a collapsible tree, and convert an array of objects to CSV for Excel or Google Sheets. Numbers are kept exactly as written, so long IDs never lose digits. Everything runs in your browser, which makes it safe for API responses and private data.

Frequently asked questions

Is my JSON sent to a server?

No. Formatting, validation and conversion all happen in your browser on your own device. Your data is never uploaded, so it's safe to paste API responses or files with private information.

What does Fix errors change?

It removes comments and trailing commas, turns single quotes into double quotes, adds quotes around property names, changes True/False/None to true/false/null, and adds missing commas between items. A message lists exactly what was fixed.

Why does another tool change my large numbers?

JavaScript can only store whole numbers exactly up to 9,007,199,254,740,991. Many tools round bigger IDs. This formatter keeps every number exactly as you wrote it.

How does JSON to CSV work?

Give it an array of objects (or an object holding one). Each object becomes a row and each key a column. Nested objects become dotted column names such as owner.name, and arrays are kept as JSON text in a single cell.

How big a file can I format?

Files of several megabytes work well in a modern browser. Very large files may take a moment, and the colour highlighting switches off for outputs over about 400 KB to keep the page fast.

Keep exploring
  • Free
    Developer

    Word to HTML Converter

    Turn Word documents (.docx) or text pasted from Word into clean HTML or Markdown for any website, CMS or email.

    • DOCX to HTML
    • Markdown
    • Paste from Word
  • Free
    Developer

    Base64 & URL Encoder / Decoder

    Encode and decode Base64 text and files, turn images into data URIs, and encode, decode or parse URLs.

    • Base64
    • Data URI
    • URL decode
  • Free
    Productivity

    Password Generator

    Create strong random passwords and passphrases, see their real strength, and check your own password privately.

    • Strong passwords
    • Passphrases
    • Strength check
For makers

Have an AI Tool?

Submit your AI tool and help others discover it.