Format JSON
Validate and neatly indent a JSON file.
- 1Choose files
- 2Adjust your options
- 3Preview & save
Free to use. No added watermarks.
Drop a file here
Or choose from your device. Your originals stay unchanged.
JSON · 20 MB per document (25 MB for PDF) · 50 MB total · max. 20 files
Processed on your device. No file upload.
How to use Format JSON
- Choose a JSON file.
- Adjust the available options and process your file.
- Review the result, then copy or download it.
When to use Format JSON
Read or compact JSON with two-space, four-space, or no indentation. Invalid syntax produces an error; the original file remains unchanged.
Supported formats and limits
JSON → JSON. Reformatting does not change the intended data. JavaScript number precision applies; duplicate object keys retain the last value.
Try a small packing list
Download our original packing-list JSON. It has a trip name, two list items and a numeric people value of 2. Choose 2-space indentation to make the structure easier to read, or Compact to remove optional whitespace. Neither option changes those values.
Formatting does not repair invalid JSON
JSON needs double quotes around property names and strings. Comments and trailing commas are not accepted. If a rerun fails, the previous successful output remains labelled as a previous result. Correct the input and generate again; downloading the older result will not apply your latest settings.
Know when an unchanged value is not enough
The formatter parses and writes JSON. Duplicate object keys collapse during parsing, numeric spelling can change, and integers beyond JavaScript's safe range can lose precision. Encode long identifiers as strings. Do not use this tool when you must preserve the exact input bytes, duplicate keys or a signed JSON document.
About this tool
Why does JSON with a trailing comma fail?
A trailing comma is not valid JSON. Remove the comma after the final property or list entry, and try again. The formatter does not guess a repair.
Does Compact compress the file into a ZIP?
No. It removes optional JSON whitespace. The result is still a JSON file, not an archive.
Is it safe for long account or tracking numbers?
Keep identifiers as quoted strings. JavaScript numbers cannot represent every integer larger than 9,007,199,254,740,991 exactly. Parsing a larger numeric identifier can change it.