JSON Formatter & Validator
Use this free JSON formatter and validator to verify JSON instantly. Paste any JSON string and the tool checks syntax, highlights errors by line number, and beautifies your output with clean indentation. Whether you need to validate JSON from an API response, debug a config file, or simply format messy JSON into readable structure — this free online JSON checker handles it in one click
Drag & drop a .json file to load it
Output will appear here...
What are JSON verification Rules?
JSON verification rules define the strict format that JSON data must follow to be considered valid. In JSON, every key must be written inside double quotes, and all string values must also use double quotes—single quotes are not allowed. Key–value pairs must be separated by a colon, and each pair should be separated by a comma, but importantly, trailing commas are not permitted. JSON structures rely on proper use of brackets: curly braces {} are used for objects, and square brackets [] are used for arrays, and every opening bracket must have a matching closing one. The values in JSON are limited to specific data types, including strings, numbers, booleans (true or false), null, objects, and arrays—values like undefined are not valid. Additionally, JSON does not support comments, so including // or /* */ will make it invalid. Overall, JSON must be clean, properly structured, and strictly formatted, as even a small mistake like a missing quote, extra comma, or unmatched bracket will cause it to fail validation.
Common JSON Syntax Errors & How to Fix Them
| Error Type | What Causes It | Example | How to Fix |
|---|---|---|---|
| Trailing comma | Comma after last item in object or array | {"name": "John",} | Remove the comma before } or ] |
| Single quotes | Using ' instead of " for strings | {'name': 'John'} | Replace all single quotes with double quotes |
| Unquoted keys | Object keys missing double quotes | {name: "John"} | Wrap every key in double quotes |
| Missing comma | No comma between two key-value pairs | {"a":1 "b":2} | Add a comma between every pair |
| Mismatched brackets | Unclosed { } or [ ] | {"items": [1, 2, 3} | Ensure every opening bracket has a matching closing bracket |
| Unescaped characters | Special characters not escaped in strings | {"path": "C:\Users\file"} | Escape backslashes and quotes with a backslash \ |
| Comments in JSON | JSON does not support // or /* */ comments | {"name": "John" // user} | Remove all comments — use JSONC format if comments are needed |
* Paste your JSON above — errors are highlighted by line number automatically.