Guides中文

JSON formatter and validator

Paste JSON to pretty-print it, check that it is valid, or compress it to a single line. Processing happens locally, so API responses and config files with secrets stay on your machine.

Files are processed in your browser and never uploaded.

How to use

  1. Paste your JSON into the input box.
  2. Choose the indentation and whether to sort keys.
  3. Click “Format” or “Minify”, then copy or download the result.

Features

Frequently asked questions

Why is my JSON invalid?

The most common causes are a trailing comma after the last item, single quotes instead of double quotes, unquoted keys and comments. Standard JSON allows none of these.

Is my data uploaded?

No. Formatting uses your browser’s built-in JSON parser; nothing is sent anywhere.

Can it handle large files?

Files of several megabytes work fine. Very large documents depend on your device’s memory.

Are big numbers preserved?

Integers larger than 9,007,199,254,740,991 cannot be represented exactly in JavaScript and may lose precision when reformatted. Store such IDs as strings.

Related tools