JSONL Viewer / Formatter

JSONL (also called NDJSON) is the format you use when streaming JSON over a network or storing one object per line in a log file. This viewer parses each line independently, highlights which row broke, and gives you per-row navigation plus bulk format conversion. Everything stays in your browser — paste production logs without worrying about uploads.

How to use the JSONL Viewer / Formatter

Paste JSONL or load a .jsonl / .ndjson / .log file. Parse runs validation line by line — each row gets its own pass/fail badge with line number and (for failures) the exact parse error. Use the Show filter to focus only on broken rows when debugging a stream. The Pretty / Compact buttons reformat every valid row in place so you can switch between two-space indent and one-line-per-record.

About JSONL Viewer / Formatter

JSONL — JSON Lines, sometimes called Newline-Delimited JSON (NDJSON) — is the de-facto format for streaming data and machine-readable logs. Each line is an independent JSON document with no enclosing array, which means you can append to the file without rewriting it, and you can process one record at a time without buffering the whole stream. OpenAI fine-tuning files, BigQuery exports, structured app logs (Pino, Bunyan), Kafka dumps, and most ML datasets ship as JSONL because the format is forgiving: a corrupted line breaks one record, not the whole file.

The tradeoff is that standard JSON validators choke on it. JSON.parse() on a multi-line JSONL file throws on the second {. This viewer parses line-by-line, treats every line as its own document, and surfaces the row index of any failures so you can fix or skip just the broken ones. The Pretty mode is useful for code review (rows expand for diffing); Compact is what you want before re-uploading to a tool that expects strict JSONL.

Common use cases

  • Debugging streaming logs — find which specific log line corrupts your pipeline.
  • Validating an OpenAI fine-tuning file before upload — bad lines surface here, saving an API rejection.
  • Quick eyeball of a BigQuery / Snowflake export without loading it into pandas first.
  • Cleaning a Kafka dump by filtering to valid rows only and re-exporting.

Frequently asked questions

Does it load files larger than browser memory?

No — files load fully into memory like any client-side tool. For multi-GB JSONL, use a stream processor like jq, jc, or a Python script. Browser tools work well up to ~100MB.

Are blank lines errors?

They're skipped silently, not counted as errors. Trailing whitespace and blank lines at the end of a file are common and treating them as broken rows would create noise.

Can it convert JSONL to a JSON array?

Use the Compact mode then wrap with [ and ] manually, or pipe through JSON Formatter. The viewer focuses on per-row inspection; for bulk conversion to array form, use jq: jq -s . file.jsonl.