Developer

JSON Formatter & Validator

Format, minify and validate JSON with exact error locations, keeping big numbers and duplicate keys exactly as written.

JSON

About this tool

Paste or drop JSON to format it with 2 spaces, 4 spaces or tabs, or minify it to one line. Invalid JSON is pointed out at the exact line and column with a plain explanation, like a missing comma or a single-quoted string.

Most formatters parse JSON into JavaScript first, which quietly changes numbers above 9007199254740991, rounds long decimals and drops duplicate keys. Interformat keeps every number’s exact digits and every key, and tells you about anything other tools would change.

Sorting keys is available but off by default, and arrays always keep their order. Turn on JSON with comments to accept // and /* */ comments and trailing commas, as in tsconfig and VS Code settings files.

Why does my number look different in other tools?

JavaScript stores numbers as 64-bit floats, so integers beyond 2⁵³ and decimals with more than about 17 significant digits can’t be held exactly. This formatter never converts them, so they stay as written.

Is my JSON sent anywhere?

No. It’s parsed in your browser and nothing is saved; reloading the page clears it.

esc
  • Opens in its own window, like any app
  • Works without an internet connection
  • Starts instantly from your home screen or dock

Look for the install icon at the right end of your browser’s address bar, or open the browser menu and choose Install Interformat.