Validate JSONL and NDJSON one complete record at a time
JSON Lines stores separate complete JSON values on successive lines. This validator checks records individually and can collect them into one JSON array or split an array back into lines.
When should you use it?
- Diagnose a malformed line in an event log.
- Convert an NDJSON export for a JSON-only API.
- Create line-oriented records from an array.
Example: two independent records
Each input line is validated separately before the records are collected into one array.
{"id":1}
{"id":2}[
{"id":1},
{"id":2}
]A line is the record boundary
In JSONL, each record line contains one complete JSON value; this tool rejects interior blank lines. A pretty-printed object spread across several physical lines is therefore not one valid JSONL record. Newlines inside a string must be escaped as \n so the record stays on one physical line. This makes the format convenient for logs and exports where records are handled individually.
Choose conversion direction before checking the result
Converting JSONL to JSON collects the records into an array. Converting a JSON array to JSONL writes each item on its own line without the outer brackets. Keep the order when it carries meaning, such as event chronology. This browser tool operates on the supplied text within its input limit; it is not a streaming processor for an arbitrarily large log file.
Inspect a stream one record at a time.
JSONL stores independent JSON values on separate lines. Validate each line and view the records together as a JSON array.
Paste JSON Lines
Use .jsonl or .ndjson text, or switch to JSON array input.
Validate each record
Malformed lines are identified by their line number.
Convert
Copy or download JSON array or JSONL output.
How do I find the invalid line in an NDJSON export?
Paste the line-oriented file into the JSONL validator. Each record line must contain one complete JSON value without commas between lines; interior blank lines are errors. The report names the failing line, which is easier to fix than parsing the entire file as one JSON document.
Two valid JSON Lines records
jsonl{"id":1,"event":"open"}
{"id":2,"event":"close"}The tool can also collect these two lines into a JSON array. An interior blank line is reported, so remove accidental gaps in the source.
Is JSONL the same as a JSON array?
No. JSONL has one independent value on each line; an array wraps items in brackets and separates them with commas. Choose the export format required by the next system.
What should you check before using the result?
An interior blank line is an error, and the total input is limited to 1 MiB. A JSONL file is not one valid JSON document without conversion.
JSON versus JSONL
A JSON document contains one root value. JSONL contains one complete JSON value on each nonblank line, with no commas between lines. This tool can turn the line sequence into an array and reverse that conversion.
Per-line limits
The total input is limited to 1 MiB. Each line is checked with the strict JSON parser. No records are uploaded or stored in browser storage.
Technical reference: JSON syntax and interoperability · RFC 8259