JJSONForge
Get JSONForge

JsonForge · JSON errors

Unexpected non-whitespace character after JSON

Two documents concatenated. JSON.parse reads exactly one value and refuses whatever follows it.

If the source is newline-delimited JSON (one object per line), split on newlines and parse each line separately — the whole file is not one document.

The smallest input that causes it

{"a":"b"}{"c":"d"}

JSON.parse on that gives, verbatim:

Unexpected non-whitespace character after JSON at position 9 (line 1 column 10)

The fix

[{"a":"b"},{"c":"d"}]

That version parses.

Find it in your own document

Paste the JSON and get the error located by line and column, the document formatted, a schema inferred from it, and a diff against another version.

Open JsonForge

Other JSON errors