JSON Validator Online
Paste JSON and find out immediately whether it parses — and if it does not, exactly which line breaks it. Toggle Beautify to read the document indented without changing what you typed.
Input
Report
About this tool
A validator answers one question: does this parse, and if not, where does it break. The report panel shows your document with line numbers and marks the failing line, while the status bar names the problem and links straight to the character. Valid documents get their shape summarised instead — key count, nesting depth and size — which is usually the next thing you want to know. Beautify only changes how the report is displayed; your input stays exactly as you typed it.
How to use it
- 1Paste the JSON you want to check into the input panel.
- 2Read the verdict in the status bar — on failure it links to the exact line and column.
- 3Toggle Beautify to view the same document indented, and press it again to see it as typed.
Frequently asked questions
›What makes JSON invalid?
The five classics: a trailing comma after the last item, single quotes instead of double quotes, unquoted keys, a comment, and NaN or undefined as a value. JavaScript object literals allow all of those — JSON does not.
›Why does the error say "position" instead of a line?
The browser reports a character offset. This page converts it into a line and column and marks that line in the report, so you can jump straight to it instead of counting characters.
›Is a single number or string valid JSON?
Yes. Since RFC 7159 any JSON value is a valid document, so 42, "text", true and null all validate on their own. Older parsers that require an object or array at the top level may still reject them.
›Does this check my JSON against a schema?
No — this validates syntax, not shape. It tells you the document parses; it does not check that a field is present or has the right type. Schema validation is a separate tool.
›Are comments allowed in JSON?
Not in standard JSON. Formats like JSONC and JSON5 add them, and tools such as VS Code accept them in config files, but a strict parser will reject a comment as a syntax error.