Tools · JSON

Fix invalid JSON

Dots on the bad lines, plain sentences, one button. Nothing changes until you say so, and Undo puts back the exact bytes you pasted.

JSON, YAML, XML, CSV, a log file, or something broken. It stays in this tab.
try
no signup · runs entirely in your browser · ⌘V works anywhere on this page

What it does

  • Reads the webhook sample as “Not valid JSON yet · 46 fixable” — 46 fixes in 7 kinds: 31 × quote unquoted key, 7 × remove trailing comma, 3 × single → double quotes, 2 × python false → json false, 1 × insert missing comma after value, 1 × python true → json true, 1 × python none → json null
  • Rewrites only the lines it names; every other byte of your text is left exactly as pasted
  • Counts the verdict down as you fix lines yourself — no button, it re-reads as you type
  • Undo (⌘Z) restores the original text, byte for byte, after Fix all
  • Runs 20 repair steps over a JSON document, listed on the JSON docs page straight from the engine

What it will not do

  • Guess at content. A missing value stays missing; the problems list says so, and nothing is invented to fill it.
  • Reorder keys, reformat, or re-indent a line it did not fix.
  • Use a language model. The fixes are rules, and the same input gives the same output every time.
  • Send your text anywhere. The page is static and the engine runs in this tab — open the network panel and watch it stay empty.

The sample

The text below is what the first chip opens — a real document the engine reads, not an illustration written for this page.

broken-webhook-example.json
{
  id: 'evt_1P8xQm2eZvKYlo2C',
  object: "event",
  api_version: "2026-03-20",
  created: 1745247128,
  type: 'payment_intent.succeeded',
  livemode: False,
  data: {
…

How

  1. Paste the text into the field above, or press ⌘V anywhere on this page.
  2. Read the verdict in the Head — “Not valid JSON yet · N fixable” — and press Show me for the list, one sentence per line.
  3. Press Fix all. The lines it rewrote turn green; ⌘Z puts the original back.

Questions

Which JSON errors does it fix?

Unquoted keys, single-quoted strings, trailing commas, a missing comma between members, Python and JavaScript literals (True, False, None, undefined, NaN), comments, and the rest of the 20 steps the JSON docs page lists — generated from the engine, so the list cannot claim a step that does not run.

Is my JSON uploaded?

No. There is no server that reads it: the page is static and the engine runs in your browser tab. Nothing you paste is sent anywhere.

What if a problem cannot be fixed?

It stays on the list with its line and the reason. Fix all applies the fixes it can and leaves that line exactly as you wrote it.

Can I fix JSON pasted out of a Python log?

Yes — single quotes, True, False and None are each one fix. The Python dict page shows that case on its own.

Try it on the file that broke your afternoon.

free while in alpha · no signup