How to format JSON
Paste or open a file
Paste your text into JSON input, or use Open file to read a local .json or .txt file. Choose two spaces, four spaces or a tab for indentation, then press Format. Sample gives you a small object to try. Copy puts the current output on your clipboard; Download saves it as formatted.json.
Inspect its structure
Tree view shows objects, arrays and their children with type labels and item counts. Open a node to inspect it, or use Expand all and Collapse all. For more than 5,000 value nodes, the page skips the tree preview and explains why. The text output still contains the complete value.
This formatter preserves number literals such as 12345678901234567890, 1.0 and 1e5 without converting them to JavaScript numbers. String escapes are preserved too.