JSON1

JSON1 / JSON Formatter

Format JSON

Paste or upload JSON to format, validate, inspect, and export it in seconds.

Processed locally
InputJSON
Ready
OutputFormatted JSON

Formatted JSON data will be displayed here...

About this tool

JSON is a text format for structured data. It replaced XML for most APIs by being smaller and quicker to read, without giving up the ability to describe nested structures. A JSON document is just a string, with a handful of characters carrying all the meaning:

  • {}Braces hold an object — an unordered set of key/value pairs.
  • []Brackets hold an array — an ordered list of values.
  • ""Double quotes wrap every string, and every key.
  • :A colon separates a key from its value, which may itself be an object or an array.
Why does {name:'json'} fail validation?
JSON requires double quotes on both keys and string values, so that has to be {"name": "json"}. Single quotes and bare keys are valid JavaScript object literals, not valid JSON — which is the single most common reason a payload that looks fine gets rejected.
Why is my trailing comma an error?
JSON does not allow a comma after the last element of an object or array. {"a": 1,} is invalid. JavaScript, Python, and most linters tolerate it, so it survives right up to the point something strict parses it.
Can I include a comment?
No. JSON has no comment syntax, which is why formats like YAML and TOML exist for configuration files that humans maintain. If you need comments in a config, convert to one of those.
Is my data uploaded anywhere?
No. Every tool on this site runs in your browser. Nothing is sent to a server, so you can paste a production payload without it leaving your machine.