Streaming NDJSON Validator

Validate a JSON Lines file or pasted records, or export a complete JSON array.

On-device No sign-up Free to use

Validate NDJSON controls

Drop your text file here

or choose one from your device

One UTF-8 file up to 64 MiB. It is read in chunks in your browser, one line at a time, and is never uploaded.

    ?

    One JSON value per line, up to 1,000,000 UTF-8 bytes. A chosen file replaces this text.

    ?

    Array conversion reads the full source, up to 1,000,000 bytes and 10,000 lines. It refuses invalid input instead of exporting a partial array.

    ?

    Turn this on for a strict record file. A line holding a number, a string, null or an array is then reported.

    ?

    This setting is about blank lines inside the file, such as the empty line left by two line breaks in a row. A final line break at the end of the file is not counted as a blank line, and a file with no final line break still has its last line read as a record.

    ?

    Reading stops at this many lines. The limit is 5,000,000 lines.

    Result

    Showing an example.

    Validate two pasted object records on separate lines.

    Read 29 bytes and 2 records from pasted.ndjson. Every line is valid.

    Loading the tool. Your result will appear here.

    https://usefreetools.net/ndjson-validator · 20 November 2026

    Was this helpful?

    How to use Streaming NDJSON Validator

    1. Choose one NDJSON or JSON Lines file, or paste one JSON value per line. A selected file replaces the text.
    2. Choose Validate each line or Convert to one JSON array. Validation streams larger files; array conversion reads the complete smaller source.
    3. Turn on Every line must hold an object when your consumer requires objects. Choose how to handle blank lines. Lines to check limits validation only.
    4. Select Validate NDJSON. Read physical line numbers and any early-stop notice. Array conversion provides ndjson-array.json only when the accepted source is valid.

    Example: Streaming NDJSON Validator

    Validate two pasted object records on separate lines.

    You add
    Or paste NDJSON records: {"name":"Ada"} {"name":"Bob"}; Operation: validate; Every line must hold an object: false; Empty lines: skip; Lines to check: 1000000
    You get
    Read 29 bytes and 2 records from pasted.ndjson. Every line is valid.

    Options

    Validation or array conversion
    Validation reads a file in chunks and returns counts with the first 100 problem details. Array conversion parses the complete accepted source and exports one formatted JSON array; a malformed record stops conversion instead of exporting a partial array.
    Object records
    Off by default, because a JSON Lines record may be any JSON value. Turn it on when every record must be an object; arrays, strings, numbers, booleans and null then fail that requirement.
    Blank lines
    Blank physical lines are skipped by default. Choose Report them when the receiving system rejects empty records. A final newline ends the last record without creating another blank record.
    Validation line limit
    Validation checks up to the configured number of physical lines, including blank or invalid lines. The default is 1,000,000 and the ceiling is 5,000,000. A stopped run describes only the portion checked; this setting does not truncate array conversion.

    Supported inputs and limits

    • One UTF-8 file up to 64 MiB, for streaming validation, read in chunks so the whole file is not held as text.
    • One line is capped at 1,000,000 characters: a longer line is reported once and the rest of that line is discarded rather than buffered.
    • Reading stops at the line limit you set and at the 64 MB byte ceiling, and the problem table lists the first 100 faults while the count stays complete.
    • The text must be UTF-8; a character cut in half at the end of the file is reported rather than dropped.
    More details

    Strict mode requires one object per line and rejects arrays and bare values.

    Paste is bounded at 1,000,000 UTF-8 bytes.

    Array conversion accepts at most 1,000,000 bytes and 10,000 physical lines and refuses malformed input.

    Output is limited to 2,000,000 characters.

    Array conversion ignores Lines to check and processes the whole accepted source.

    JSON numbers use JavaScript number precision; preserve exact large identifiers or decimals as strings before conversion.

    Where your input is processed

    This tool does not upload your inputs. See the limits for anything saved on your device.

    Why streaming changes what the page can promise

    The file is read in chunks and each complete line is checked separately. The page keeps only a bounded unfinished line and the first 100 problem details, while counting all problems. Oversized lines are reported and discarded until the next newline. You receive the report after the run finishes or reaches its configured limit.

    Questions about Streaming NDJSON Validator

    What is the difference between NDJSON and JSON Lines?

    Both use one JSON value per physical line. This page checks that shared structure and accepts a final record with or without a closing newline. It can also require objects or report blank lines when your reader needs stricter records.

    Why is the reported line number higher than I expected?

    The number counts every physical line from the first one, including blank lines and lines that hold invalid data. That is the number an editor shows next to the text.

    What happens to a file with one enormous line?

    The buffer stops at the per-line cap, the line is reported as too long, and the rest of that line is thrown away as it arrives so the page does not run out of memory.

    Can I check only the first part of a large file?

    For validation, set Lines to check to a smaller number. The report says when it stops and does not claim that later records passed. Array conversion instead processes the complete accepted source within its smaller file and line limits.

    Page updated · Project managed by Tony Hines · Report a problem with Streaming NDJSON Validator