Code Issues Releases

Releases

v1.0.0 — Initial release

v1.0.0 · August 30, 2026

main

First stable release of csv-to-json, a lightweight, dependency-free CSV-to-JSON converter (Python 3.10+, stdlib only).

What it does

Converts CSV data to JSON from file paths, raw strings, or stdin — usable as a CLI or imported as a library.

Highlights

  • Type inference: numeric, boolean (true/yes, false/no), and empty-to-null casting (opt out with --no-type-inference)
  • Nested key expansion: dot-notation headers like user.address.city become nested JSON objects (--expand-keys)
  • Streaming: stream_csv_to_json() yields records one at a time for large files
  • Flexible I/O: custom delimiters (-d), stdin/stdout piping, file output (-o), compact or pretty output

Usage

python src/csv_converter.py data.csv -o output.json
cat data.csv | python src/csv_converter.py - --compact

MIT licensed.