{·}jsontools.me
JSON GUIDE

JSON trailing commas, explained

Why JavaScript may accept a construct that strict JSON rejects, and how to remove it safely.

4 minute read · Updated August 2026Validate strict JSON

Strict JSON has no trailing commas

A comma separates values or members; it does not terminate the final member. JavaScript object literals, JSON5, and many configuration formats are more permissive, which is why the mistake is easy to make.

{ "enabled": true, }

Why the distinction matters

A tolerant editor may load the document while an API client, database, or standards-compliant parser rejects it. Validation mode should match the consumer, not the tool that happened to open the file.

Repair without changing values

Removing a comma immediately before a closing brace or bracket is deterministic as long as the scanner respects quoted strings and comments. Reparse the exact repaired result afterward.