JSON Formatter
Paste JSON, format or minify it, and find out precisely which line and column broke it.
关于此工具
Formatting and minifying here work on the token stream rather than parsing your document into a JavaScript value and printing it back out. That round trip quietly corrupts two things: integers longer than about sixteen digits lose precision, and keys that look like numbers get reordered. Several widely used online formatters ship both bugs. Your document comes back byte for byte as you wrote it, with only the whitespace changed.
使用方法
- Paste your JSON into the input pane, or load the sample.
- Choose an indent width, then press Format. Press Minify instead to strip every optional byte.
- Copy the result or download it as a file. If the document is invalid, the failing line is marked in the gutter.