Skip to content

Repair broken / invalid JSON

repair fixes the common mistakes that make a JSON file invalid, so it becomes parseable and openable: trailing commas, missing or extra brackets, unquoted keys, single quotes, comments, and truncated endings.

jsonreshape repair broken.json repaired.json --report fixes.csv
  • repaired.json is the fixed file; the original is left untouched.
  • --report fixes.csv writes a list of every change that was made, so nothing is fixed silently.

In the desktop app

When a file fails to parse, the error panel offers a Repair… button. It shows what will be changed before it writes the fixed file.

Tips