JSON Error Locator

Paste JSON and see exactly where it breaks — line, column and character offset for every syntax error, each with a plain-English cause, a suggested fix, and a caret under the offending character. Nothing is uploaded.

Try:
Diagnosis

Find where your JSON breaks, not just that it broke

Parsers tell you something is wrong and stop at the first mistake. Paste the document above and this tool tells you where — a 1-based line, a character-counted column, and a 0-based offset for every syntax problem it finds — plus a plain-English cause, a concrete fix, and a caret pointing at the exact character. Everything runs in your browser; the text is never uploaded.

What it names

Worked example

Input:

{
  "name": "Ada",
  "tags": [1, 2,]
}

Diagnosis (default settings):

Invalid JSON — 1 issue found.
A parser stops at line 3, column 17.

1. Line 3, column 16 (offset 34) — trailing comma
   Cause: this comma is the last thing in the array; JSON does not allow a comma before ].
   Fix:   delete this comma (or add another value after it before the ]).

   1 | {
   2 |   "name": "Ada",
   3 |   "tags": [1, 2,]
     |                ^
   4 | }

Switch Result format to machine-readable JSON and the same run returns {valid, issue_count, issues[], parser_stop, summary} — one object per issue with kind, label, line, column, offset, explain, fix and the snippet — ready to pipe into a script or a CI check.

Valid input still tells you something

A document that parses returns a summary instead of an error: the top-level value's type, how many members or elements it holds, the nesting depth, and the line/byte count.

Limits and edge cases

FAQ

Why does the reported column point just after my mistake?

Because that is where the document first stops making sense. A missing comma is only detectable at the start of the next thing — by the time "b" appears on line 3, the comma that should have ended line 2 is already missing. The same applies to unclosed brackets: the error surfaces at the end of the file, not where you forgot the }. The report flags the detection point and reminds you to look at the line above; for unclosed containers it points back at the opening bracket instead.

How is this different from a plain JSON validator?

A validator runs a real parser, which aborts at the first error — a file with five mistakes takes five edit-and-retry rounds. This tool runs the parser and a tolerant scanner that keeps going after each problem, so all five are listed at once with individual positions, causes and fixes. Set Report every issue off to get the single-error, parser-style behaviour instead.

My JSON came from JavaScript or Python and nothing parses it. What now?

That is the most common case here: single quotes, unquoted keys, True/None/undefined, NaN, and // comments are all valid in those languages and none of them are JSON. Each one is named individually with the exact replacement to make — for example Truetrue, or name:"name":. Fix them top-down and re-run; the issue list shrinks as you go.

Is my data uploaded anywhere?

No. The diagnosis is compiled to WebAssembly and runs entirely in your browser tab — no request carries your JSON off the page, so pasting a config file or an API response with credentials in it is safe. Closing the tab is all the cleanup there is.

What do the context-lines and offset controls do?

Context lines sets how many source lines are printed above and below each flagged line, with a caret under the exact column — 2 by default, 0 to drop the snippets and get a compact list of positions, causes and fixes. The offset in each heading is a 0-based character offset from the start of the document, which is what String.slice, seek, and most editor "go to position" commands want.

Can it fix the JSON for me?

Not here — this tool's job is the diagnosis, so you can see and understand every problem before changing anything. Repairing malformed JSON, and re-indenting JSON that is already valid, are separate tools; use the machine-readable output if you want to drive a fix from a script.

Developer & Automation Access

Run it from the terminal

Same engine as this page, headless — via the gizza CLI:

gizza tool json-error-locator '{
  "name": "Ada",
  "tags": [1, 2,]
}'

New to the CLI? Get gizza →

Open it by URL

Pre-fill and auto-run this tool with query parameters — the names match the API/CLI:

https://gizza.ai/tools/json-error-locator/?json=%7B%0A%20%20%22name%22%3A%20%22Ada%22%2C%0A%20%20%22tags%22%3A%20%5B1%2C%202%2C%5D%0A%7D&output=report&context_lines=2&scan_all=true

Machine-readable descriptor: tool.json — title + parameters JSON Schema for agents.