What this tool does
A JSON array becomes one JSON document per line.
[
{ "id": 1, "name": "Ada" },
{ "id": 2, "name": "Grace" }
]
{"id":1,"name":"Ada"}
{"id":2,"name":"Grace"}
Each line is minified, and that is not a stylistic choice: a pretty-printed document spans several lines, and in NDJSON a line break means next record. Indentation and the format are mutually exclusive.
The root has to be an array
The array is the list of records. An object at the root is one document, and splitting it into lines would mean deciding that its keys are records — a guess this tool will not make. The conversion stops instead.
The items themselves are unconstrained: null, 42 and "text" are valid JSON documents and therefore valid NDJSON lines. Records are usually objects, but nothing here requires it.
Long integers keep their digits
[{ "id": 12345678901234567890 }]
comes out with all twenty digits. A converter that parses through a JavaScript number writes 12345678901234567000 instead, silently — the value changes and the file still looks perfectly well-formed.
This one used to do exactly that. It was found while writing this page and fixed; the identifier now survives the round trip through NDJSON and back.
An empty array gives an empty file
[] produces no output at all, and that is the correct answer: NDJSON has no way to write “zero records” other than an empty file. It does mean an empty result and an empty input look alike — worth knowing before you conclude that nothing happened.
Private by design
Everything runs locally in your browser with JavaScript. Your data is never uploaded, which makes the tool safe for sensitive content, and it keeps working offline.