TestFinch

Format and validate JSON

Format JSON and find the line and column of an error.

Runs in your browser. Nothing is uploaded.

Loading the tool

Snag files a bug with its screenshot, console and network attached, and your coding agent can pick it up. Free, no card.

Try Snag free

An API response on one line is hard to read, and a JSON error message rarely says where the problem is. This tool formats JSON so you can read it, and when the JSON is not valid it shows the line and column of the first error.

How to use it#

  1. Paste JSON into the box, open a .json file, or try the sample.
  2. Choose the indent: 2 spaces, 4 spaces, a tab, or None to minify it onto one line.
  3. The formatted JSON appears beside it as you type. Copy it, or download it as a .json file.
  4. If the JSON is not valid, the line and column of the first error are shown with the line itself and a mark under the spot, and what was expected there.

It changes only whitespace#

Formatting never changes your data. Numbers are copied exactly as written, so a 64-bit ID such as 1234567890123456789 stays exact, and values such as 1e999, 1.10 and -0 are kept as they are. Keys keep their order, and a duplicated key is kept and counted rather than silently dropped, since many parsers keep only the last one. That matters when you format a response to file a bug: the developer sees what the server sent.

Large files#

Text over 5 MB is formatted in the background, so the page stays responsive, and a very long result shows its first 2,000 lines with copy and download for the rest. Text up to 20 MB is accepted. JSON nested more than 1,000 levels deep is valid but too wide to indent, so the tool suggests None to see it on one line.

Common errors it finds#

A trailing comma after the last item, single quotes instead of double quotes, a missing comma between items, an unclosed bracket, a number with a leading zero, and a line break inside a string.

Questions#

Is my JSON sent anywhere?#

No. The formatter runs in your browser.

How large a file can I format?#

Up to 20 MB. Inputs over 5 MB are formatted in the background so the page stays responsive.

Does it fix my JSON?#

No. It shows where the error is so you can fix it.

Will it round big numbers?#

No. Numbers are copied as written, so large IDs keep every digit.