JSONL ⇄ JSON

NDJSON logs and LLM datasets to a JSON array, and back again.

About & FAQ ↓
Input
Waiting for input.
Output
Reference
JSONL ⇄ JSON

About the JSONL ⇄ JSON converter

JSON Lines is how logs, data exports and LLM fine-tuning datasets travel: one JSON document per line, appendable and streamable. It is also awkward to inspect, because no ordinary JSON tool will parse the file as a whole. This converts a .jsonl file into a proper array you can read, search and feed to the other tools here, and flattens an array back to one record per line.

01

Logs and datasets

Built for the NDJSON that log exports and LLM fine-tuning files actually ship as.

02

Bad lines by number

One corrupt record in fifty thousand is named, not hidden behind a generic failure.

03

Skip and continue

Convert everything that parses and get a count of what was skipped.

04

Both directions

Array to one-record-per-line, or a .jsonl file into an array you can actually read.

How to use it

  1. Paste JSONL (one object per line) or a JSON array — the direction is detected.
  2. Invalid lines are named by line number; tick "Skip invalid lines" to ignore them and convert the rest.
  3. Copy or download the result as .json or .jsonl.

Questions

What is the difference between JSONL and NDJSON?

Practically none — both mean one JSON value per line, separated by newlines. The names are used interchangeably, and this tool reads and writes both.

One line in my export is corrupt. Can I still convert it?

Yes. By default it refuses and tells you which lines are bad; tick "Skip invalid lines" and it converts everything else, reporting how many it skipped.

Is this useful for OpenAI fine-tuning files?

Yes — those are JSONL. Convert to an array to inspect or edit the set, then convert back to JSONL for upload.