Arrange the structure clearly, leaving the values and content intact.
Enable JavaScript for interactive processing. You can read the instructions, limits, and FAQs below without it. Files are processed only in your browser.
JSON FormatterUser Guide
Indent JSON to 2 cells, 4 cells or compact format, only adjust the spaces between tokens, and retain large integers, -0, exponent writing, original escapes, key order and duplicate keys.
How to use
Paste JSON or import a single UTF-8 .json.
Select the output format, click Organize and check duplicate key reminders and previews.
Copy the complete results or export a JSON copy.
Formats and limits
The maximum size of the original text is 2 MiB and 100 layers; the maximum size of the typesetting result is 20 MiB.
Does not accept comments, trailing commas, or incomplete syntax; previews up to 50,000 UTF-16 code units.
Output
Keep a JSON copy of the original number and string token.
Frequently asked questions
Are large numbers that exceed JavaScript safe integers rounded?
No. The collator retains the original text of the number and does not perform full JSON.parse/JSON.stringify round-trips; duplicate keys are not merged.
The file name and content are only processed in your browser and are not transmitted to the server. The original file will not be overwritten. Please export the required results before leaving the tool.