Convert JSON to JSONL
Convert a JSON array to line-delimited JSONL. Runs entirely in your browser, so your data never leaves your device.
0 chars · 0 lines
Output
The result appears here as you type.
How to use Convert JSON to JSONL
- 1. Paste your JSON array. Paste a JSON array where each item is the record you want on its own line, such as a list of log events or training examples.
- 2. Review the JSONL output. There are no settings to adjust: each array item is minified and written on its own line, with no surrounding brackets or commas between records, matching the JSON Lines convention exactly.
- 3. Copy the JSONL result. Copy the line-delimited output and save it as a .jsonl file, ready for tools that stream records one at a time, such as log processors or machine learning data loaders.
When to use Convert JSON to JSONL
Convert JSON to JSONL turns a JSON array into JSON Lines, also called newline-delimited JSON, where each record sits on its own line instead of inside a shared array. This format lets consumers process one record at a time without loading the entire array into memory first.
- Preparing training data for a machine learning pipeline. Many ML frameworks expect training examples as JSONL, one JSON object per line, rather than a single large JSON array, especially for streaming large datasets.
- Formatting logs for a streaming ingestion pipeline. A log aggregation tool consumes one JSON event per line rather than a full array, and your events currently sit together inside a single JSON array from an export.
- Appending records without rewriting an entire file. You want a file format where new records can be appended to the end without parsing and rewriting the whole document, which a single large JSON array does not support cleanly.
- Feeding bulk data into an Elasticsearch or similar bulk API. A bulk import API expects newline-delimited JSON documents rather than one large array, and your source data currently lives as a single JSON array.
Examples
Convert an array to JSON Lines
Input
[{"a": 1}, {"a": 2}]Output
{"a":1}
{"a":2}About the Convert JSON to JSONL tool
Convert JSON to JSONL does its work locally, right in the browser. Convert a JSON array to line-delimited JSONL. There is no upload step, no queue and no account, and your data never travels over the network.
It belongs to the JSON Tools collection on EditSafely, a set of 90 small, focused JSON utilities that share the same instant, private workspace.
There is nothing to configure. Provide the input and the result appears on its own. A worked example further down the page shows exactly what the tool produces for a real input.
Running locally also makes the tool fast and dependable: results appear as you type or drop a file, there is no server outage that can take it down mid-task, and confidential data can be processed without a second thought.
Frequently asked questions
Does Convert JSON to JSONL cost anything?
Yes, it is completely free. All 2,658 tools on EditSafely work without an account, a subscription or usage limits.
Is it safe to paste sensitive or confidential data?
No data leaves your device. The whole tool is JavaScript that runs inside your browser tab, so there is no upload, no server-side processing and no log of what you did. If you disconnect from the internet after the page loads, it keeps working.
How much text can I process at once?
There is no fixed limit. Because the work happens on your own device rather than on a shared server, the practical ceiling is your machine's memory, which comfortably handles inputs far larger than typical online tools allow.
Do I need to sign up or install anything?
Nothing to install and no account needed. Open the page in any up-to-date browser, including on a phone or tablet, and the tool is ready.
How do I use the result?
The output panel has a one-click copy button, and you can keep refining the input while you work; the result updates in place as you type.