Zum Inhalt springen
uencoder

Formatieren, validieren, und repair malformed JSON

Nehmen ein JSON Zeichenkette (possibly minified, mit trailing commas, oder comments) und produce gültig, indented JSON mit Fehler diagnostics.

  1. 1

    JSON from APIs is often minified for transport, and JSON from humans often has errors (trailing commas, single quotes, comments). Formatting makes it readable; validation catches structural errors before parsing fails in production.

  2. 2
    JSON-Validator →

    Paste the JSON. The tool reports whether it is valid and, if not, the exact location and nature of the syntax error (unexpected token, missing comma, unterminated string).

  3. 3
    JSON-Formatierer →

    Paste valid (or valid-ish) JSON to re-indent it with 2 spaces, sort keys if desired, and normalize whitespace for consistent diffs.

  4. 4

    Use the chain to validate-then-format in one pass: if validation fails you get the error; if it passes you get formatted output.

Häufige Fragen

Why does my JSON with comments fail validation?
Standard JSON (RFC 8259) does not allow comments. Some parsers (JSON5, JSONC used by VS Code) accept them, but strict JSON does not. Strip comments before sending to a strict parser, or use a JSONC-aware parser.
Can the tool fix trailing commas automatically?
Strict JSON forbids trailing commas. The validator flags them; some formatters can strip them during formatting. However, automatic repair can mask real errors — always review the diff after any auto-fix.

Workflows, die diese Aufgabe lösen

BLAKE-Hash mit CRC32-Prüfsumme
BLAKE-Hash berechnen dann CRC32-Prüfsumme für Integritätsverifikation.
PIPELINE
Namenskonvention umwandeln und als JSON validieren
Bezeichner in Ziel-Namenskonvention umwandeln, dann Ausgabe als JSON validieren zur Strukturbestätigung.
PIPELINE
Zwei YAML-Konfigurationen über JSON vergleichen
YAML-Konfigurationen in JSON umwandeln für diff-freundlichen Vergleich strukturierter Werte.
PIPELINE
JSON-Nutzlast für URL-Transport kodieren
Ein JSON-Dokument für URL-Parameter vorbereiten: pretty-print, Base64-kodieren, dann percent-kodieren — die exakte Umkehrung der verschachtelten Parameter-Dekodierungskette.
PIPELINE
Text hashen und mit CRC32-Prüfsumme verifizieren
Sowohl einen kryptografischen SHA-256-Hash als auch eine CRC32-Prüfsumme berechnen zur Datenintegritätsverifikation.
PIPELINE
HJSON zu JSON-Format
HJSON formatieren und in Standard-JSON umwandeln.
PIPELINE
JS formatieren und JSON validieren
JS-Code formatieren dann als JSON validieren.
PIPELINE
JSON formatieren und Integritäts-Prüfsumme berechnen
Ein JSON-Dokument pretty-printen und eine CRC32-Prüfsumme berechnen zur Erkennung nachfolgender Änderungen.
PIPELINE
JSON minifizieren und validieren
JSON für Inspektion formatieren und syntaktische Korrektheit in einem Durchgang validieren.
PIPELINE
JSON Schema generieren und validieren
Ein JSON Schema aus Beispieldaten generieren dann dagegen validieren.
PIPELINE
JSON formatieren und TypeScript-Interface generieren
Ein JSON-Dokument formatieren dann eine TypeScript-Interface-Definition inferieren in einer Kette.
PIPELINE
Validieren, formatieren, dann JSON zu YAML umwandeln
Eine (möglicherweise minifizierte) JSON-Konfiguration in YAML umwandeln, Syntaxfehler am ersten Knoten abfangen statt subtil falsches YAML zu erzeugen.
PIPELINE
JSON5 zu JSON-Format
JSON5 formatieren und in Standard-JSON umwandeln.
PIPELINE
JSONC zu JSON-Format
JSONC (JSON mit Kommentaren) formatieren und in Standard-JSON umwandeln.
PIPELINE
JWT-Payload dekodieren und formatieren
Ein JWT-Token parsen, Payload extrahieren und JSON formatieren für Inspektion.
PIPELINE
Query-String parsen und JSON formatieren
Query-String in Schlüssel-Wert-Paare parsen dann als JSON formatieren.
PIPELINE
SHA3-256-Hash mit CRC32-Prüfsumme
SHA3-256-Hash berechnen dann CRC32-Prüfsumme für duale Integritätsverifikation.
PIPELINE
TOML in JSON umwandeln
Eine TOML-Konfigurationsdatei in JSON parsen fuer Tools und APIs, die JSON-Eingabe erwarten.
PIPELINE
TOML ueber JSON in YAML umwandeln
Eine TOML-Konfigurationsdatei in YAML-Format umwandeln, mit JSON als Zwischendarstellung.
PIPELINE
Verschachtelten URL-Parameter dekodieren (Base64 JSON)
Einen URL-Parameter, der URL-kodiertes Base64-JSON transportiert, in lesbares formatiertes JSON entfalten.
PIPELINE
TypeScript-Interfaces aus YAML generieren
Ein YAML-Dokument in TypeScript-Interface-Definitionen umwandeln, mit JSON als Zwischenformat.
PIPELINE
YAML validieren und formatieren
YAML zu JSON umwandeln zur Strukturvalidierung, dann bestaetigen, dass das JSON well-formed ist.
PIPELINE

Verwandte Tools