JSON
JSON Repair
Reparatur von beschädigtem JSON — überzählige Kommas, einfache Anführungszeichen, Schlüssel ohne Anführungszeichen, Kommentare, Python-Literale (True/False/None) und mehr — mit einer Liste aller angewendeten Korrekturen.
Data that claims to be JSON often has small deviations from the spec: a trailing comma, single quotes, unquoted keys, Python literals like True/False/None instead of true/false/null. This tool fixes such issues automatically and lists every fix it applied.
How to use it
- Paste broken JSON and the tool immediately tries to fix syntax issues and shows the valid result.
- The list below shows each applied fix separately, so you can check exactly what changed.
- If it can't be repaired (the structure is too damaged), the tool points to the exact line where parsing stopped.
Common uses
- Fixing JSON copied from logs or a console, where strings may have been truncated or escaped incorrectly.
- Converting a Python-style dict (with True/False/None and single quotes) into valid JSON.
- Parsing an LLM response that promised JSON but added a comment or a stray comma.
Things to keep in mind
The tool only fixes syntax errors — it won't catch a broken data structure (a missing field, swapped values), since that kind of JSON is still syntactically valid.
If the damage is severe enough (a string cut off mid-way, for example), the automatic fix can produce an unexpected result — always check the output before using it.
Artikel zu diesem Tool: JSON Repair: warum JSON kaputtgeht und wie man es repariert
Häufig gestellte Fragen
Welche Arten von Fehlern kann das Tool reparieren?
Überzählige Kommas, einfache statt doppelte Anführungszeichen, Schlüssel ohne Anführungszeichen, in JSON nicht erlaubte Kommentare, Python-Literale wie True/False/None sowie fehlende Kommas oder Doppelpunkte, unter anderem.
Kann das Tool jedes beschädigte JSON reparieren?
Nein, bei stark beschädigter Eingabe — etwa mitten in einem Wert abgeschnittenem Text — gibt es manchmal keine eindeutig „richtige“ Reparatur, sodass die ursprünglichen Daten nicht zuverlässig wiederhergestellt werden können.
Sieht oder sendet das Tool das eingefügte JSON irgendwohin?
Nein, die gesamte Reparatur erfolgt lokal im Browser über JavaScript, es wird nichts an einen Server übertragen.
Was tun, wenn das Reparaturergebnis falsch aussieht?
Prüfen Sie das Ergebnis immer manuell, besonders an den Abbruchstellen. Die automatische Korrektur trifft die „am wenigsten zerstörerische“ Annahme (etwa einfach offene Klammern zu schließen), kann aber nicht erraten, welcher Wert gemeint war, wenn die Daten schwerer beschädigt sind.
Behebt das Tool auch logische Fehler in den Daten?
Nein, nur syntaktische. Fehlt in den Daten ein ganzes Feld oder sind Werte vertauscht (aber das JSON selbst ist syntaktisch korrekt), erkennt das Tool das nicht — das ist kein Syntaxfehler.