JSON5 Validator — Check JSON5 Syntax With Error Reporting
Validate JSON5 with line and column error reporting. Supports comments, trailing commas, single quotes, hex numbers.
How to use
- 1 Paste your JSON5 — comments, trailing commas, single quotes all welcome.
- 2 See the green Valid pill, or a red error pill with line and column.
- 3 The right pane shows the parsed value as standard JSON.
- 4 Copy or download the JSON output.
Why use this tool
- Powered by <code class="font-mono text-xs">json5</code> — the reference JSON5 implementation.
- JSON5 lets you author config files with comments, trailing commas, hex numbers, and more.
- Errors include line and column so you can find them fast.
- Pure client-side — input stays in your browser.
Frequently asked questions
What is JSON5?
JSON5 is a superset of JSON with extensions: comments, trailing commas, single-quoted strings, unquoted keys, hex/Infinity/NaN literals, and more.
Is JSON5 the same as JSONC?
No — JSONC (VS Code's "JSON with comments") only adds comments. JSON5 also adds trailing commas, unquoted keys, single quotes, etc.
Related tools?
<a class="text-brand-600 hover:underline" href="/json-formatter">JSON Formatter</a> for strict JSON; <a class="text-brand-600 hover:underline" href="/yaml-formatter">YAML Formatter</a> if you want full YAML.
What is JSON5 Validator?
A JSON5 Validator is a tool that checks whether text conforms to the JSON5 specification and reports syntax errors with line and column positions. It accepts JSON5 features that standard JSON rejects, including comments, trailing commas, single-quoted strings, and hexadecimal numbers. Running client-side in the browser, it validates and parses JSON5 input without uploading it to a server.
Features
Spec-accurate validation
Parses with the reference json5 library and reports the exact line and column of any error.
Full JSON5 syntax
Accepts comments, trailing commas, single quotes, unquoted keys, and hex/Infinity/NaN numbers.
100% private
Validation runs on your device — nothing is uploaded.
Example
Input
{ /* comment */ a: 1, b: 'two', c: 0xff, }
Output
Valid ✓ → parses to {"a":1,"b":"two","c":255}
Common use cases
-
1
Validate config files
Check a .json5 or JSON5-style config (Babel, some build tools) before committing.
-
2
Catch trailing-comma issues
Confirm which relaxed features your input uses and where it still errors.
-
3
Convert JSON5 to JSON
Parse JSON5 to see the strict-JSON value it represents.
Zerethon's JSON5 validator checks whether text conforms to the JSON5 specification and reports syntax errors with line and column positions, in your browser. JSON5 extends JSON with comments, trailing commas, single-quoted strings, unquoted keys, and hexadecimal numbers. Everything runs client-side — your input is never uploaded.
- Category
- Developer
- Pricing
- Free
- Privacy
- Browser-based
- Signup
- Not required
References
Privacy
Your data never leaves your browser unless explicitly stated. JSON5 Validator runs entirely client-side — no server upload, no logging, no tracking of your input.
Learn the basics
Related tools
JSON Formatter
Format, validate, and minify JSON online. Free, no signup — your data never leaves your browser.
Open toolSQL Formatter
Format SQL queries online — beautify MySQL, PostgreSQL, SQLite, SQL Server, Oracle, and BigQuery.
Open toolUUID Generator
Generate UUIDs online — v1, v4, v7, and Nil. Bulk generation up to 10,000. Free, no signup.
Open toolPassword Generator
Generate strong, cryptographically random passwords. Configurable length and character sets — runs in your browser.
Open toolBuild, share, and grow on Zerethon Social
Free signup. Earn points, collect achievements, and connect with creators worldwide.