What is a JSONL file?

JSONL — JSON Lines

What is it?

JSONL refers to exactly the same thing as NDJSON: one JSON object per line. Two names, two communities, a single format — worth knowing before you waste time hunting for a difference that isn't there.

Usage has settled the matter in practice: people tend to say JSONL in machine learning circles, and NDJSON in the world of application logs and data streams.

History & origin

The .jsonl extension spread alongside the explosion of datasets for artificial intelligence, where each line represents a single training example.

It's now the format expected by most model fine-tuning tools: one line, one sample.

Why it is useful

It lets you process datasets several gigabytes in size without ever loading the whole thing into memory.

Adding data simply means appending lines to the end of the file — no rewriting required.

Limits & drawbacks

It can't be read by tools that expect standard JSON.

The lack of an enclosing structure makes it impossible to validate the file as a whole.

Practical tips

JSONL is the format to use for a training dataset or any stream-based processing.

Convert it to CSV to inspect it in a spreadsheet, or to JSON if a tool requires a single array — but watch out for memory usage if the file is large.

Convert your JSONL in seconds, on our secure servers in France.

Convert a JSONL