JSON Position Finder
Position 1234 means nothing. Line 7 does.
Paste the document here and the message above. I’ll find the spot.
Ctrl+Enter finds · drop a file on this pane
Every parser counts. Not every parser counts the same way.
Paste the error message from your parser and the JSON it was reading. The finder reads the position the way that parser counts — UTF-16 units, characters or bytes, from 0 or from 1 — and shows the exact spot. It runs in your browser.
How to find a JSON error position
- Paste the message: “at position 1234”, “line 7 column 3 (char 210)”, “offset 98” or “BytePositionInLine: 12”.
- Paste the JSON the parser read, exactly as it was. For a file with Windows line breaks, tick CRLF.
- See the line, column and character; Show me puts the cursor on it.
Position, char, offset: why JSON parsers disagree
JavaScript counts UTF-16 code units from 0, Python counts characters from 0, and Go, .NET and MySQL count bytes. An emoji is 2 units, 1 character and 4 bytes, so one spot has three numbers. Next to the spot, the finder lists all of them, so any log line points to the same place.
JSON position finder FAQ
What does “Unexpected token in JSON at position 0” mean?
Position 0 is the very first character: the response wasn’t JSON at all. Most often it is an HTML error page or an empty body, so check the status code and the raw response before parsing.
Is the position counted from 0 or from 1?
Offsets — position, char, offset — count from 0; lines and columns usually count from 1. .NET is the exception: LineNumber and BytePositionInLine both count from 0.
Why is the spot off by a few characters?
Either the text is not the one the parser read, or the file had Windows (CRLF) line breaks: each is two characters in the file and one in a browser text field. Tick CRLF and look again.
Which messages does it understand?
Node.js and Chrome, Python, Firefox, .NET System.Text.Json, MySQL, RapidJSON, Go encoding/json and jq, plus any “line L column C” and a bare number.
Other tools
- JSON Formatter — 2 spaces, 4 spaces or tabs, order kept.
- JSON Validator — exact line and column for every error.
- JSON Diff — what changed, with JSON Pointer paths.
- JSON Viewer — a tree with search and a path for every node.
- Base64 Encode & Decode — in your browser, nothing sent.
- JWT Decoder — header, payload and expiry, decoded in your browser.
- JSON to Query String — arrays, nesting and spaces your way, and back.
- Unicode Unescape — \u0430 from DevTools into letters, in your browser.
- JSON Minifier — one line, every byte accounted for.
- JSON to YAML — same order, same numbers, safe quoting.
- YAML to JSON — numbers as written, anchors expanded, no guessing.