← All notes

Lay out Parquet files as row groups and column chunks

Answer: Read the format page together with the Thrift definition. A Parquet file starts and ends with the 4-byte magic number PAR1. File metadata lists the start locations of every column chunk.

File layout

The file opens with a 4-byte magic number PAR1 and closes with the same 4-byte magic number. Between them sit column chunks arranged in row groups, then file metadata, then a 4-byte little-endian length of that metadata.

A table with N columns is split into M row groups. File metadata stores the start locations of all the column chunks. Writing metadata after the data allows single pass writing. Readers should first read the file metadata to find the column chunks they are interested in, then read those chunks sequentially.

| PAR1 | file metadata | |---|---| | 4-byte magic number | start locations of column chunks | | little endian length | written after the data | | row groups | N columns split into M groups |

ColumnChunk and RowGroup

In Thrift, ColumnChunk may name a file where column data is stored. If that field is not set, the data is assumed to be in the same file as metadata, and the path is relative to the current file. Optional fields include the OffsetIndex file offset and its size in bytes, plus the ColumnIndex file offset.

Metadata is kept separate from the data by design. Columns can be split into multiple files, and a single metadata file can reference multiple parquet files.

See also

Claims

Sources

License: this note is CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Summary by iinventedlight (AI-assisted). Sources: Apache Parquet docs, Parquet File Format; Apache parquet-format, parquet.thrift (ColumnChunk, RowGroup). Apache-2.0. Text was condensed and changed from the originals.

License: CC-BY-4.0 · Summary by iinventedlight (AI-assisted). Sources: Apache Parquet docs, Parquet File Format; Apache parquet-format, parquet.thrift (ColumnChunk, RowGroup). Apache-2.0.

Cite this

Permanent ID: iil:note:cvg6b4ze

iinventedlight. 2026. "Lay out Parquet files as row groups and column chunks." iinventedlight Library, iil:note:cvg6b4ze, version of 2026-11-20. https://iinventedlight.com/library/notes/parquet-row-groups/. License: CC-BY-4.0.

@misc{iil_note_cvg6b4ze,
  author = {{iinventedlight}},
  title = {{Lay out Parquet files as row groups and column chunks}},
  howpublished = {iinventedlight Library},
  year = {2026},
  date = {2026-11-20},
  url = {https://iinventedlight.com/library/notes/parquet-row-groups/},
  note = {Permanent ID iil:note:cvg6b4ze. License: CC-BY-4.0.},
}

Markdown

Spotted a mistake? Use the MCP feedback tool or email hello@iinventedlight.com. Or Report a correction (no account needed).

Extra files beside this note

These files use this note's license, shown below. Paper extras retain their reproduction status; a link is not a reproduction.

All artifact files (JSON index)

For language models and agents: start at /llms.txt | /agents.md | /.well-known/agent-library.json. This page in Markdown: /library/notes/parquet-row-groups.md.