DAP Foundry dap.solutions
validate-json-first-error · client-spa · v1 · stub

Validate JSON

Paste JSON and learn whether it is valid, or see the line and column your browser reports for the first syntax error, or line 1 column 1 when it reports none. Runs in this tab. Your inputs stay in this browser.

Input

Text that should be JSON. Up to 1 MB (1,048,576 bytes) and 50,000 lines. A line break at the very end does not count as another line.

Output

ok when valid. Otherwise error: line L column C, the position your browser's JSON parser reports at the end of its message. When it reports none, the answer is line 1 column 1. Lines and columns start at 1. Columns count UTF-16 code units, as JavaScript does, so an emoji can count as one column (such as ✅), two (most emoji) or four or more (flags, skin tones, joined emoji).

Limits

How this was made

The core transform was written by hand into the stub registry.

Errors

Input with no characters at all, or over 1 MB or 50,000 lines, names the field and the rule. Input of only spaces or blank lines is reported as a syntax error.

Inputs not stored

This runs in your browser tab. Your inputs are not uploaded or stored. The tool sets no cookie, uses no local storage and sends no analytics about your inputs.