Skip to content

This file type cannot be converted in the browser.

┌─ FILE ANALYSIS ────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
DEVELOPER : N/A (Community standard)
CATEGORY : Data
MIME TYPE : application/x-ndjson
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────

What is an NDJSON file?

NDJSON (Newline-Delimited JSON, also called JSON Lines) is a text format where each line contains a valid JSON value, typically a JSON object. Unlike regular JSON arrays, NDJSON can be processed line by line without loading the entire file into memory, making it ideal for streaming, logging, and large datasets.

How to open NDJSON files

  • Any text editor — Each line is a JSON object
  • jq (Command-line) — jq . file.ndjson for formatting
  • Pythonfor line in open(): json.loads(line)
  • DuckDBSELECT * FROM 'file.ndjson'

Technical specifications

PropertyValue
Line FormatOne JSON value per line
SeparatorNewline (\n)
EncodingUTF-8
StreamingLine-by-line processing
Also Known AsJSON Lines (.jsonl), LDJSON

Common use cases

  • Logging: Structured application logs (ELK stack).
  • Data streaming: Apache Kafka, AWS Kinesis payloads.
  • Bulk APIs: Elasticsearch bulk indexing format.
  • Data exchange: Large dataset export/import.