To make JSON readable, keep an original copy, open the JSON Formatter, and select Format. The output uses two-space indentation. It passes through JSON.parse and JSON.stringify, so changes can extend beyond whitespace.

Choose format, minify or validate

Action Current implementation Check before use
Format Parses, then serializes with two spaces Important values, types and keys
Minify Serializes without indentation Not gzip; spaces inside strings remain
Validate Checks whether JSON.parse succeeds Does not validate JSON Schema or business rules

Valid syntax does not prove that a postcode exists, required fields are present or an identifier is exact.

A reproducible example

{"name":"Taro","id":"00123","active":true,"note":null}
{
  "name": "Taro",
  "id": "00123",
  "active": true,
  "note": null
}

"00123" is a string and retains its leading zeros. An unquoted 00123 is not a valid JSON number. A standalone null, false, 0, empty string or array is also valid JSON; the top-level value need not be an object.

Values and spelling that can change

Input Minified result Implication
{"id":9007199254740993} {"id":9007199254740992} Integer rounding outside the safe range
{"id":"9007199254740993"} Same string Preserve IDs as strings if the contract permits
{"x":1,"x":2} {"x":2} Earlier duplicate member is lost
{"value":1.00} {"value":1} Decimal spelling is not preserved
{"2":"b","1":"a"} {"1":"a","2":"b"} Integer-like property order changes

The JavaScript safe-integer upper bound is 9,007,199,254,740,991. It does not imply exact representation of all smaller decimal fractions. Turning an already rounded number into a string cannot recover its digits. Preserve originals for financial records, identifiers and signed payloads; check the data contract and a diff before replacement.

Numeric ID 9007199254740993 rounds, whereas the string ID retains its digits
Type matters even when the digits look identical. Select the diagram to enlarge.

Fix common syntax errors

Invalid input Correction Reason
{'name':'Taro'} {"name":"Taro"} Double-quoted keys and strings
{"x":1,} {"x":1} No trailing comma
{"x":/*note*/1} {"x":1} No comments
{"x":NaN} Contract-dependent, e.g. null NaN and Infinity are not JSON numbers

Use \n for a newline inside a string rather than inserting a literal line break. Browser error messages vary and do not always include a line number. Check punctuation immediately before the reported position. JSONC and JSON5 configuration files require their own parsers.

File workflow and limits

  1. Keep an original copy and begin with a small example without secrets.
  2. Paste JSON or select a JSON file.
  3. Format or minify; compare important IDs, numbers and keys.
  4. Copy the output or download the JSON file.

Processing happens in the browser; the implementation does not upload the input. This does not promise that opening the site involves no network traffic or that browser extensions cannot read a page. Capacity depends on the device, browser and structure. We have no universal line-count or file-size guarantee. For large files, keep the original and consider a local editor.

Frequently asked questions

Does formatting always preserve content?

No. The table above shows changes beyond whitespace. Do not use this workflow to preserve original bytes or signatures.

Is valid JSON ready for my API?

Syntax is only one check. Verify field names, required fields, types and ranges against that API’s contract.

How do I create a spreadsheet instead?

Read the CSV/JSON conversion guide first: nulls, empty cells and types may be lost during conversion.

Return to the same workflow

Open the JSON Formatter and reproduce the examples above. Use the favorite control near the tool name to reopen it from My Tools in the same browser. Favorites store tool choices, not the entered content. Clearing site data removes them.

Scope of this update

On October 24, 2026, we compared these examples with the published implementation. Primary references explain the underlying rules; the tables describe this tool. This is not a speed or capacity benchmark.