Fix invalid JSON in one click
JSON copied from JavaScript, Python, logs or LLM output is often almost valid. Click Repair (or Try auto-repair on the error card) and the tool rewrites it as valid, formatted JSON. The sample above shows a typical case.
How to use it
- Paste the broken JSON into the Input panel.
- Click Repair in the toolbar. The input is replaced with valid JSON and a summary of the fixes is shown.
- Review the result. Press Ctrl+Z to undo if needed.
What Repair fixes
- Trailing commas, missing commas and extra commas
//,/* */and#comments- Single quotes, backticks and curly “smart” quotes
- Unquoted keys and bare text values
- Python
True,False,None; JavaScriptundefined,NaN,Infinity - Unclosed or mismatched brackets, JSONP wrappers,
const x =prefixes, and newline-delimited JSON
More JSON tools
All tools are free and run privately in your browser.
JSON Repair FAQ
Can every broken JSON be repaired?
Most common mistakes can. If the input is too ambiguous, Repair tells you where it got stuck. Always review the repaired result before using it.
Can I fix JSON from an LLM or ChatGPT response?
Yes. Model output often has trailing commas, comments, single quotes or a missing closing bracket, which are exactly what Repair fixes.
Can I undo a repair?
Yes. The repair is applied as a normal edit, so Ctrl+Z (Cmd+Z on Mac) restores your original text.
Is my data uploaded to a server?
No. The JSON Repair runs entirely in your browser using JavaScript. Your data is never uploaded, logged or stored, and the tool keeps working offline after your first visit.