What is this tool?
This JSON formatter pretty-prints, minifies and validates JSON side by side: paste on the left and the formatted result appears on the right as you type. Errors show the exact line and column with a pointer, and Repair fixes common mistakes such as trailing commas, single quotes, comments, unquoted keys and Python True/None. The Tree view lets you collapse, expand and search large documents and copy the path of any value. You can also sort keys, escape or unescape strings, convert to YAML, XML, CSV or a TypeScript type, load a file, and share the JSON as a link. Numbers are kept exactly as written. Nothing is uploaded.
How to Use
- Paste JSON into the input pane, open a file, or drop a .json file on it.
- Pick an indent (2, 4 or Tab). The output pane formats as you type; press Beautify or Ctrl+Enter to format now.
- If the JSON is invalid, read the line and column in the output; the input jumps to the error. Press Repair to fix trailing commas, single quotes, comments and unquoted keys.
- Switch the output to Tree to browse and search keys and values, or Stats for counts and depth.
- Copy or download the result, convert it to YAML, XML, CSV or TypeScript, or press Share link to copy a link that contains the JSON.
Frequently Asked Questions
Is my JSON uploaded?
No. Parsing, formatting and repair run in your browser. Share link packs the JSON, compressed, into the part of the URL after #, which browsers never send to a server; anyone you give the link to can read it.
Why do trailing commas fail?
Standard JSON forbids them, as well as single quotes, comments and unquoted keys. Press Repair to fix these automatically, then check the output and press Use as input to keep editing.
Are large numbers kept exactly?
In Chrome, Edge and other browsers that support JSON.rawJSON, formatting keeps numbers exactly as written, including IDs above 9007199254740991 and values like 1.50. Other browsers show a warning when an integer is too large to keep exactly.
How do I find a key in a large document?
Open the Tree view and type in the search box. Matching keys and values are highlighted and their parent objects stay open. Each row has a Copy path button that copies a path such as $.items[0].name.
Other tools
There are more calculators, converters and editors on Wivrix. If something is missing, tell us.