1. Home
  2. Developer tools
  3. JSON Lines Converter

JSON Lines Converter

Work with log exports, BigQuery dumps and AI fine-tuning files that store one JSON object per line.

Free, no sign-up. Runs in your browser: nothing is uploaded.

How to use JSON Lines Converter

  1. Paste or open a .jsonl or .ndjson file.
  2. Pick a conversion.
  3. Copy or download the result.

Features

  • Line numbers for every invalid line, with the parser’s message
  • Skip bad lines or stop at the first one
  • Nested objects flattened to dotted CSV columns
  • Columns collected from every record, not just the first
  • JSON array and CSV back to JSONL

Supported formats

You can open

  • JSONL
  • NDJSON
  • JSON
  • CSV

You get

  • CSV
  • JSON
  • JSONL

Private by design

Your files are opened and processed by your browser on this device. They are never uploaded to openWorkstand or anyone else, so the JSON Lines Converter is safe for contracts, IDs, photos and work documents. After you have used it once while online, it also works without an internet connection. How local processing works

Good to know

  • Arrays inside records stay as JSON text in CSV cells rather than becoming extra rows.

Guide

Working with JSON Lines: validating, flattening and converting

JSON Lines, also called NDJSON, is the format of application logs, analytics exports, message queues and AI training data: one JSON value per line, so a file can be appended to and processed one record at a time. It is ideal for machines and awkward for people, because spreadsheets cannot open it and a single broken line stops most parsers. This converter checks every line and turns the file into CSV, a JSON array or clean JSON Lines.

The format in one paragraph

The rules from jsonlines.org are short: the file is UTF-8, each line holds one complete JSON value, and lines are separated by a newline. Pretty-printed JSON that spans several lines is therefore not valid JSON Lines. Most files hold one object per line, but any JSON value is allowed. Blank lines are not part of the specification; the converter simply ignores them.

Line-by-line validation

Every non-empty line is parsed on its own. A line that fails is listed with its line number and the parser’s message, so you can find a truncated record or a stray comma at once. With “Skip invalid lines” on, the bad lines are left out and the rest is converted; turn it off when a missing record would make the output wrong and you would rather stop.

Flattening for CSV

CSV has no nesting, so objects inside a record are flattened into dotted column names: {"user":{"name":"Ada"}} becomes a column called user.name. Arrays stay as JSON text in one cell, because spreading them into extra columns or rows would change what a row means. Columns are collected from every record in the order they first appear, not just from the first line, so a field that only shows up halfway through the file still gets its column.

A worked example

The Sample has five lines of event data, and line 4 is cut off in the middle of a record. In JSONL to CSV mode the tool reports “Line 4” as invalid, skips it and writes four data rows under the header id,event,user.name,user.plan,tags,ts,amount. The third row is 3,purchase,Ada,pro,,2026-10-30T09:12:40Z,49.5: the tags cell is empty because that record has no tags, and amount comes last because it first appears in that record.

The other conversions

JSONL to JSON array wraps the valid records in square brackets for tools that expect a single document. JSON array to JSONL does the reverse, writing each element on its own line. CSV to JSONL reads a spreadsheet export with a header row and produces one object per row with string values, a common first step when building a fine-tuning or evaluation file. Clean JSONL rewrites every record compactly, which also repairs files where someone pretty-printed the records.

What does not survive

CSV values are text, so numbers and booleans lose their type on the way back from CSV to JSON Lines. Arrays in CSV cells remain JSON strings. Very large files work, but the whole file is held in the browser tab, so multi-gigabyte logs are better split first.

Files for AI fine-tuning

Chat fine-tuning formats expect one object per line with a messages array. Building them from a spreadsheet works in two steps: export the examples to CSV, convert them here to JSON Lines, then reshape the fields in a script or with the Prompt Template Filler. Running the finished file back through validation confirms that every line parses before you upload it.

  • CSV to JSON converts spreadsheets to a regular JSON document.
  • JSON Formatter pretty-prints and validates a single record.
  • Parquet Viewer opens the columnar files many pipelines produce from JSON Lines.
  • JSON to SQL loads records into a database table.

Checked against the current version of the JSON Lines Converter on .

Troubleshooting

The file does not open

Check that it is one of the supported formats above and opens in another app. Damaged files and password-protected PDFs cannot be read until they are repaired or unlocked.

It is slow or stops on a very large file

Everything runs on your device, so speed depends on its memory. Close other tabs, use a computer rather than a phone, or split the file into smaller parts first.

The download did not start

Look for your browser’s download bar or icon. Some browsers ask once before a site may download files; allow it and click the button again.

Frequently asked questions

How do I open a JSONL file in Excel?

Convert it to CSV here and open the CSV. Excel has no JSON Lines import of its own; Power Query can read JSON, but each line has to be parsed separately, which the converter does for you in one step.

Why are some CSV cells empty?

Records in a JSON Lines file do not need the same keys. When a record lacks a field that another record has, its cell in that column is left empty, which keeps every row aligned under the right header.

What is the difference between JSONL and NDJSON?

None in practice: both mean one complete JSON value per line, separated by \n. JSON Lines (jsonlines.org) and NDJSON are two names for the same format; the .jsonl and .ndjson extensions are interchangeable.

Can a JSON Lines record span several lines?

No. Each record must be on one line, so pretty-printed JSON is not valid JSONL. Use the Clean JSONL option to compact records back onto single lines.

Keep working with the result

After you download, choose “Save to Workstand” to keep the result in a folder on your computer, attach it to a project and create a follow-up task. It is saved by your browser, not uploaded.