json formatter and validator
runs in your browser, nothing is uploaded
IDLE
Paste JSON, drop a file or open one, and get a formatted, foldable tree, or the exact line and column of the first error. Everything happens in this page: your data is not uploaded, and the tool keeps working without a connection once it has loaded.
What it checks
The parser is strict. Anything that is not valid JSON is reported with its line, its column and a caret under the problem, in plain words such as “Trailing comma before }” or “Keys need double quotes”. Valid input is shown as a tree you can fold, with 2-space, 4-space or tab indentation and an option to sort keys.
It also notices things a plain validator lets through. Duplicate keys are listed with the line of each copy, because most programs keep only the last one. Integers too large for JavaScript to hold exactly, such as 9007199254740993, keep every digit. Several documents on separate lines are read as JSON Lines.
Large files and odd values
Files up to 20 MB can be opened or dropped onto the input. Large input is parsed in a background thread so the page stays usable, and the tree draws the first levels, then fills in the rest as you open it.
Numbers that look like Unix timestamps show their date, links are clickable, and strings that hold JSON, base64 text or a JSON Web Token get a badge that expands them in place. Click any row to see its path, copy it, or use it as a query.
Questions
Is my JSON sent to a server?
No. Parsing, formatting and every other step run in this page. Input is saved in this browser so it survives a reload, and you can clear it from the help dialog.
Can it fix JSON that is not valid?
Often, yes. The error view lists the repairs auto-fix would make, such as removing comments or trailing commas, before you apply it. Undo brings your original back.
Does it change my numbers?
No. Numbers keep the spelling they were written with, so 1.50 stays 1.50 and long integers keep every digit.
Are there keyboard shortcuts?
Yes. Ctrl+Enter formats the input in place, Ctrl+F or / searches, the arrow keys move through the tree, and ? lists the rest.