How to validate JSON
- Paste the JSON or drop a .json file.
- A green line means it is valid, with the number of keys and how deeply it is nested.
- If not, you see the line, the column and what's wrong. Click Show the error to jump there.
The most common JSON errors
- Missing comma between two properties or array items.
- Trailing comma after the last item:
[1, 2,]— allowed in JavaScript, not in JSON. - Single quotes: JSON needs
"double"quotes for keys and text. - Unquoted text:
{"status": ok}must be"ok". - Comments:
//and/* */aren't JSON — tick Allow comments to strip them. - Leading zeros:
007isn't a valid number; write"007"or7.
Valid JSON, nicely formatted
Once it is valid you also get the formatted version, ready to copy. Want the smallest version for an API call or config value? Minify JSON.
Private by design
The JSON never leaves your browser. Paste API responses with tokens or customer data without sending them to a server.
Reading the error
The line and column point at the first character that can't be valid at that spot. The real mistake is often just before it: a missing comma at the end of the previous line, or a quote that was never closed. Click Show the error and look one line up first.
Validate API responses and config files
- API responses: copy the body from your browser's DevTools (Network tab) or from curl and paste it here.
- package.json, composer.json, appsettings.json: strict JSON — no comments allowed.
- tsconfig.json and VS Code settings: these allow comments; tick Allow comments and trailing commas.
Frequently asked questions
How do I check if JSON is valid?
Paste it here: you see "Valid JSON" or the exact line and column of the problem.
Why is a trailing comma an error?
The JSON standard doesn’t allow it, even though JavaScript does. Remove it, or tick Allow comments and trailing commas.
Can it validate large files?
Yes, files of tens of MB are checked in your browser.
Is my JSON uploaded?
No.
Why is my JSON valid in JavaScript but not here?
JavaScript accepts single quotes, unquoted keys and trailing commas; the JSON standard does not.
Does it check a JSON schema?
No — it checks that the text is valid JSON, not that it matches a schema.