About this online JSON syntax checker
A JSON validator parses your input against the JSON spec (RFC 8259) and tells you whether it's well-formed. If it isn't, you need to know where the problem is — most validators give you a useless "Unexpected token" with no location. JSONYard always reports the exact line and column, which is why teams use it as their go-to JSON checker, JSON lint, or JSON error checker.
Once your JSON is syntactically valid, you usually want to pretty-print it — open the online JSON formatter and beautifier on the home page, or jump straight to validating against a JSON Schema if you also need to check the document's shape.
Working through a specific error? See how to fix the most common JSON parse errors for the smallest fix for each one.
How to validate JSON online
- Paste, drop, or upload your JSON into the editor above.
- Click Validate. If the JSON is well-formed you'll see a green "Valid JSON" status; otherwise the exact line and column of the first error appear in the status bar.
- Click Repair to auto-fix common JSON-ish problems — trailing commas, single quotes,
// /* */comments, and unquoted keys. - For schema-level checks, send the validated output to the JSON Schema validator.
Common JSON errors
- Trailing commas —
{"a":1,}is invalid. JSON disallows the comma after the last property; many JavaScript developers expect it because JS allows it. - Single quotes —
{'a':1}is invalid. JSON requires double quotes around keys and string values. - Comments — JSON has no comment syntax. Strip
//and/* */before validating, or use Repair mode. - Unquoted keys —
{a:1}is invalid. Wrap every key in double quotes. - Mismatched brackets — every
{needs a}, every[needs a]. - Stray characters — copy-paste from PDFs or emails sometimes pulls in invisible characters like non-breaking spaces or BOMs.
- Unescaped backslashes or quotes inside strings —
"path": "C:\\Users"works,"path": "C:\Users"doesn't.
FAQ
What's the difference between a JSON validator and a JSON Schema validator?
Why is my JSON invalid in this tool but valid in my code?
json5, JavaScript's eval, etc.) that accepts comments or trailing commas. Strict JSON.parse doesn't. Use Repair mode to bridge the gap.