Skip to main content

Code & Data

JSON formatter & validator

Format, minify or validate JSON, with the line and column of any error and a warning for numbers that lose precision.

  1. 1Fill in the values
  2. 2Click Run
  3. 3See results instantly

Limits

  • Standard JSON only: comments, trailing commas and single quotes are reported as errors.
  • Integers beyond 9007199254740991 lose precision in JavaScript. You get a warning, and the formatted output shows the rounded value.
  • Duplicate object keys are collapsed to the last value, as in every JavaScript parser.

Ask the AI chat

The AI chat can run this tool for you. Try:

  • “format json: {"a":1,"b":[1,2]}”
  • “minify json {"a": 1}”
  • “validate json: {"a":}”