JSON Validator Online — Free Syntax Checker & Linter
Validate JSON instantly and diagnose syntax errors with precise line and column markers. Repair broken JSON with automatic fixes for trailing commas, comments, and unquoted keys.
Common JSON syntax mistakes
JSON (RFC 8259) is a strict subset of JavaScript object literals. Subtle differences often break standard parsers:
- Trailing commas: JSON forbids trailing commas after the last array item or object key (e.g.,
[1, 2,]). - Single quotes: All strings and keys must use double quotes (
"key", never'key'). - Unquoted keys: JavaScript allows
{ name: "val" }, but standard JSON requires{ "name": "val" }. - Comments: Comments (
//or/* */) are not permitted in standard JSON.
Frequently asked questions
How does this online JSON validator detect syntax errors?
The validator parses your JSON stream and identifies RFC 8259 syntax violations. When an error is encountered (such as an unquoted key, unescaped quote, or missing bracket), it calculates the exact line and character column where the parser failed.
Can the tool automatically fix broken JSON?
Yes. The "Fix Common Errors" button automatically strips trailing commas, transforms single quotes to valid double quotes, quotes unquoted object keys, and strips comments.
Is my JSON secure and private?
Yes. Validation executes completely on your local device inside your browser. No data is ever transmitted to remote servers.
Scroll back up and paste your JSON to check its syntax.