JSON Lines Merger

JSON Lines Merger

Merge JSON lines (JSONL/NDJSON) into a JSON array.

JSONL Input

Merged JSON Array

About The JSON Lines Merger

The JSON Lines Merger turns JSONL or NDJSON records into one formatted JSON array, which is useful when another tool expects a regular JSON document.

The merge runs locally in your browser. Invalid lines are skipped and counted in the status message, so review the source when a warning appears.

How to Merge JSON Lines Online

  1. Paste one JSON value per line into the JSON lines input box.
  2. Click Merge JSON Lines to parse valid lines.
  3. Review the formatted array and the status message for skipped invalid lines.
  4. Use Copy Output when the array is ready for import or testing.

Choosing Options Correctly

Line format:
- Put exactly one JSON object, array, string, number, boolean, or null value on each line.
- Keep multiline JSON out of this tool unless it has already been compacted to one record per line.

Invalid lines:
- A warning means at least one line was skipped.
- Fix skipped lines before using the output for production data work.

Common Use Cases

  • Converting NDJSON exports into a JSON array for inspection.
  • Preparing event records for tests or examples.
  • Cleaning mixed JSONL snippets while preserving valid records.
  • Moving log-like JSON records into tools that require array input.

Quick FAQ

Does it stop on the first invalid line?
The tool may report invalid lines and stop merging so you can fix the input before producing misleading output.

Can each line be a primitive value?
JSON Lines can contain any valid JSON value per line, but downstream tools often expect objects.

Is my JSON uploaded?
No. Merging is designed to run in the browser.

How do I find bad lines?
Check line numbers in the error output, then validate each failing line as standalone JSON.