Apache Parquet, Explained: Columnar Storage for Analytics

What is Apache Parquet?

Apache Parquet is an open-source, columnar file format designed for analytics. Instead of storing data row by row (like CSV), Parquet stores each column together, with per-column compression and rich metadata. That layout makes analytical queries dramatically faster and the files much smaller.

Want to look inside one? Open any file in the Parquet Viewer — it previews rows, shows the schema, and lets you query and export, all locally in your browser.

Why columnar? Row groups, columns and metadata

A Parquet file is organized into a few nested layers:

  • Row groups — horizontal slices of the table (e.g. a few hundred thousand rows), each processed independently.
  • Column chunks & pages — within a row group, each column is stored contiguously and compressed on its own.
  • Metadata & statistics — the footer records the schema plus per-column min/max/null statistics for each row group.

Those statistics enable predicate pushdown (skip row groups that can't match a filter) and projection pushdown (read only the columns a query needs). A query like SELECT avg(price) FROM sales WHERE year = 2024 can skip most of the file instead of scanning every byte.

Parquet vs CSV vs JSON

  • CSV — human-readable and universal, but untyped, uncompressed and slow to scan at size. Great for small, interchange-friendly data. See the CSV guide.
  • JSON — flexible and nested, but verbose and even slower for analytics.
  • Parquet — typed, compressed and columnar. Ideal for large analytical datasets and data lakes; not meant for row-by-row editing or streaming writes.

When to use Parquet (and when not to)

Use Parquet when you have large, mostly-read analytical data, when you query a subset of columns, or when storage and scan speed matter. Prefer CSV/JSON for small files, human editing, or simple interchange, and a transactional database for frequent small updates.

Inspect and query Parquet with DuckDB

DuckDB reads Parquet natively — no import step. A few useful patterns:

-- Query a Parquet file directly
SELECT * FROM 'events.parquet' LIMIT 10;

-- Inspect the schema and file metadata
DESCRIBE SELECT * FROM 'events.parquet';
SELECT * FROM parquet_schema('events.parquet');
SELECT * FROM parquet_metadata('events.parquet');

-- Convert CSV to Parquet
COPY (SELECT * FROM 'data.csv') TO 'data.parquet' (FORMAT PARQUET);

Where to go next

  1. Parquet Viewer — open a .parquet file right now.
  2. Everything about DuckDB — the engine that makes Parquet easy to work with.
  3. DuckDB Playground — try COPY ... TO (FORMAT PARQUET) yourself.

FAQ