Uncomplicating the modern data stack with DuckLake. The Lakehouse That's Just SQL & Parquet. Zero platform team required. A straight yellow arrow cuts through the middle of a dense, tangled scribble of black lines.

DuckLake, the Lakehouse That's Just SQL and Parquet, a Visual Guide

TL;DR: DuckLake is an open table format that keeps a data lake's metadata in an ordinary SQL database and its data in plain Parquet files. That one decision gets you transactions for free, swaps a chain of metadata file reads for a single SQL query, and lets the catalog be anything from a DuckDB file sitting in S3 to Postgres or DuckDB's new Quack server. DuckLake 1.0 is out, and companies are already building on it.

How many files does a query read before it reads any data? For a lot of data lakes the honest answer is more than you'd think. A table in a format like Apache Iceberg is a pile of Parquet files plus metadata files that say which Parquet files belong to the table, and in Iceberg those metadata files live on object storage too. To answer a query, an engine can end up reading JSON, Avro and manifest files first, one request after another, just to learn which Parquet files matter.

DuckLake takes the other road. Put the metadata in a real database, keep the data in Parquet, and let SQL do the bookkeeping. The format comes from the team behind DuckDB, the in-process analytical database, and it grew out of a simple question: if something in the lake already needs a database, why not use one for all of the metadata?

The payoffs follow from that choice. Transactions come built in, because SQL databases already have them. The metadata is a handful of tables anyone can read, so a new engine needs to run queries against a catalog, not learn several file formats. And since the catalog only needs a few basic column types and primary keys, you pick the database that fits: a local DuckDB file to try it out, Postgres for a shared setup, or Quack, DuckDB's client-server protocol, once it matures.

This guide goes through DuckLake one topic at a time: why file-based lakehouse formats read so many files, how a SQL catalog fixes that, the three pieces of the architecture, picking a catalog, Quack, data inlining, the "frozen" DuckLake that costs almost nothing to run, and where 1.0 leaves things today. There's also a detour into what makes DuckDB fast in the first place.

Listen to the full episode

What is an open table format, and why does Iceberg read so many files?

How many files does your query read before it reads any data? A client crosses the S3 network boundary and winds through a manifest list, manifest file, Avro and JSON before reaching Parquet data. The bloat: formats built to avoid a database reinvented a slower one. The cost: every metadata read is a round-trip.

An open table format is a layer of metadata on top of plain Parquet files that lets you query and change those files as one transactional table. In the simplest case, that metadata is a pointer to the list of files that together make up a table. Add a schema so you know what types to expect, plus statistics about which files hold which data, and you have the core of it. The "open" part matters just as much: the format has a public specification, so anyone can write a reader or writer for it. That is what's meant to keep you from being locked into one vendor, and to let you move between engines and providers. These days the same idea is often called a lakehouse format.

Apache Iceberg is the other widely used open table format, and in Iceberg everything is a file. The data lives in Parquet, and the metadata lives in files too, in formats such as JSON and Avro. An engine may need three or four different file format readers just to work out which Parquet files to open.

How did it get that way? The DuckLake team's reading is that Iceberg "grew backwards." It started as some Parquet files plus a little metadata pointing at them. Then people wanted ACID guarantees on that data, and to deliver them Iceberg stacked manifest lists and manifest files on top. Treat that as the DuckLake side of the comparison. File-based formats get something real in return: with only files on object storage, reads can scale out very widely.

The cost shows up as latency. Picture one query against S3. Request the metadata file, parse it, maybe fetch more metadata, and only then read the data. Every hop is a network request to object storage, and they happen one after another. The more snapshots a table has, the more there is to hop through, and lots of small inserts make it worse, because each one adds metadata files (more on that in the data inlining section). This is the "small file problem" anyone who has worked with data lakes will recognize.

So the question stands: how many files does your query read before it reads any data? With a file-based format it depends on the table's history, and it's rarely just one.

“it's basically just some metadata on some parquet files that you can query in a transactional manner.”

Guillermo Sanchez

Why isn't this just a database? Where DuckLake came from

The CWI Napkin Sketch Epiphany. A napkin drawing of a root file fanning out into manifests, data files, JSON, Avro and Parquet asks "Why isn't this just a database?" Iceberg and Delta already need a database to hold the latest metadata pointer. Mark Raasveldt and Hannes Mühleisen: move all the metadata into it.

DuckLake started as a drawing. DuckDB kept getting requests to support Iceberg, so DuckDB's creators, Mark Raasveldt and Hannes Mühleisen, had been looking at data lakes for a while, and metadata kept in files struck them as inefficient. As database researchers, they asked "well, why is this not just a database?"

The drawing shows Iceberg's metadata files, and at the very top of it sits a database. A file-based format still needs one somewhere, because something has to hold the pointer to the latest metadata file. If a database is in the picture anyway, why not put all of the metadata in it?

That idea fixes several things at once. Metadata in tables can be queried with SQL, and anyone can read the schema and write queries over it. A reader no longer needs a stack of file format parsers. It asks the catalog which files make up the table at a given snapshot, gets a list back, and reads them. And metadata rows in a catalog don't pile up as files on object storage the way they do with many small writes.

Why does a database seem like a heavy answer, though? Because for a long time it was. Data scientists tended to run away from database servers, since setting one up and loading data into it was a project in itself. DuckDB was built to remove that friction: it runs inside your process, starts in about half a second, and you can run a query in one line.

That's also why the catalog is flexible. Any database that supports transactions and primary key constraints can do the job, so the same design runs on a local DuckDB file for experiments and on a shared Postgres server for a team. The next sections show what that looks like.

“So what if we just put this all in the database and then I made them sign for me in case this was a very successful idea.”

Pedro Holanda

How DuckLake works: a SQL catalog plus plain Parquet files

Metadata lives in a real database. Data stays in plain Parquet. A database cylinder labeled Catalog (SQL DB) connects to a folder labeled Data (Plain Parquet). That is the entire format. ACID guarantees aren't built from scratch; they come for free from the SQL catalog.

The whole design fits in one sentence: the metadata lives in a real database, and the data stays in plain Parquet. The DuckLake specification is the schema of the SQL tables that hold the metadata, plus the queries run against them: which files belong to which table, at which snapshot, with what schema and statistics. If you can read a schema and write SQL, you can see how it works.

What does a database need to qualify as a catalog? The specification asks for transactions and primary key constraints, and in practice that means a few basic column types such as timestamp, varchar and integer. That's why the options run from DuckDB and SQLite to Postgres and MySQL.

Here's how it looks from DuckDB. The ATTACH line points at a catalog (a DuckDB file here) and a folder for the Parquet files:

INSTALL ducklake;
ATTACH 'ducklake:my_lake.ducklake' AS lake (DATA_PATH 'lake_files/', DATA_INLINING_ROW_LIMIT 0);
CREATE TABLE lake.events (id INTEGER, kind VARCHAR);
INSERT INTO lake.events VALUES (1, 'click'), (2, 'view');
SELECT kind, count(*) FROM lake.events GROUP BY kind;

After that, lake_files/ holds ordinary Parquet files and my_lake.ducklake holds the metadata. The DATA_INLINING_ROW_LIMIT 0 option switches off data inlining, which by default stores tiny writes in the catalog itself, so that even this small insert produces a real Parquet file to look at.

The biggest payoff is transactions. DuckLake didn't need to build ACID itself. When a write races another transaction, the catalog database already knows how to tell whether the other one succeeded, because that is what a SQL database is built to do.

Plain Parquet is a design choice, not a law. The catalog records what kind of file each data file is, so the spec already leaves room for other file types, at least in theory. Parquet is what you get today.

“For us, we didn't have to build any ACID. It was built into the design, basically, because the catalog service is a SQL database that already supports ACID transactions.”

Guillermo Sanchez

One SQL query instead of a chain of metadata files

The "One SQL Question" advantage eliminates network latency. Traditional formats zigzag across S3 through six metadata nodes to reach Parquet data; DuckLake goes to one catalog, then straight to Parquet. DuckLake asks the catalog: "Which files do I read for this table at this snapshot?"

What does a read look like with a SQL catalog? The engine asks the catalog one question: which files do I need to read for this table at this snapshot? The catalog answers with a list of Parquet files, plus statistics about them so the reader knows what it actually needs to open. Then the engine reads those files, and that's the whole process.

Because the catalog is a database, you can ask that question yourself. Open the catalog file from the previous section in its own session and a simplified version looks like this, with snapshot 2, the last one in that example, standing in for "the latest":

SELECT f.path
FROM ducklake_data_file AS f
JOIN ducklake_table AS t USING (table_id)
WHERE t.table_name = 'events'
  AND 2 >= f.begin_snapshot
  AND (2 < f.end_snapshot OR f.end_snapshot IS NULL);

Each data file records the snapshot it appeared in and the one that removed it, so the same table can be read as of any snapshot. In DuckDB that's SELECT count(*) FROM lake.events AT (VERSION => 2), with VERSION being the snapshot id.

For an engine, one SQL query replaces what in a file-based format usually takes more than one round trip through more than one file. That is the idea DuckLake was designed around, and it collapses the work an engine has to do to read or write the format.

It's worth being precise about what goes away: the metadata hops, not the network. The Parquet files still live on object storage and still have to be fetched, and if your catalog is a Postgres server somewhere, asking it is a network call too. What you lose is the chain of sequential S3 requests before the first byte of real data.

Doesn't the file-based approach at least scale better? "Something that's highly scalable, doesn't mean it's fast." A design can stay consistent as you add a million more users or far more data and still be slow from day one, and many back-and-forths across S3 for a single query are slow even on a small table. Files on S3 let reads scale out more or less indefinitely, and that's real. The DuckLake answer is that the catalog doesn't have to become the bottleneck. A database like DuckDB gets a lot out of modest hardware, and since the catalog only needs a few basic types and primary keys, a distributed database could in theory take the job. What matters for the catalog is the size of your metadata, not the size of your data.

“you just need one query, actually, in order to retrieve all of the information that you need to query these parquet files.”

Guillermo Sanchez

DuckLake architecture: storage, catalog and compute

The anatomy of simplicity requires only three decoupled pillars. Storage: object store (S3, GCS, Azure), only .parquet. Catalog: SQL database (DuckDB, Postgres, MySQL, SQLite, Quack). Compute: DuckDB, Spark, DataFusion. No vendor lock-in: the table format and file format have public specifications.

A DuckLake has three parts, and each one can be chosen separately.

  • Storage is any object store, usually cloud hosted: S3, Google Cloud Storage or Azure Blob Storage. It holds Parquet files and nothing else, because DuckLake has no metadata files.
  • The catalog is a SQL database holding all the metadata about those Parquet files. DuckDB's DuckLake extension, the project's own reader and writer, can use DuckDB, SQLite, Postgres, MySQL or a Quack server for the job. Some of those live next to you in-process, others on a remote server.
  • Compute is anything that can read Parquet and ask the catalog which files to read. Most people use DuckDB. A DataFusion implementation is already quite advanced, and a Spark writer exists too, reportedly built by MotherDuck because some of its customers already used Spark for ETL.

The catalog is the part you can see for yourself. Here is a DuckLake with a SQLite file as its catalog and a local folder standing in for the object store:

INSTALL ducklake;
INSTALL sqlite;
ATTACH 'ducklake:sqlite:metadata.sqlite' AS my_ducklake (DATA_PATH 'data_files/');
USE my_ducklake;
CREATE TABLE t (a INT);
INSERT INTO t SELECT * FROM range(1000);

Afterwards data_files/ holds one Parquet file, and metadata.sqlite is an ordinary SQLite database with tables such as ducklake_table, ducklake_snapshot and ducklake_data_file. The last one lists the Parquet files, so working out which files to read is just a query against the catalog.

A typical production setup keeps storage and compute separate: object storage on one side, an EC2 instance doing the work on the other. Nothing ties the storage to AWS, either. Anything that speaks the S3 protocol, DigitalOcean Spaces for one, can play that role.

Why split things this way? Openness. Both the table format and the file format have public specifications, so anyone who reads them should be able to write a reader and a writer. That is meant to avoid vendor lock-in. Migrating off a database like Oracle is famously painful and costly, while an open format means you can, at least in theory, move between engines and providers (Databricks, Snowflake, your own DuckDB-based setup). And because the data is plain Parquet, spreading reads across lots of machines is easy.

“So by just reading the specification, anyone should be able to implement a reader and writer to that format, right?”

Pedro Holanda

Columnar vs row storage: why DuckDB is fast at analytics

Columnar storage and vectorized execution unlock analytical speed. A row store holds (Apple, $1, Qty 5) and (Banana, $2, Qty 10) as rows; an "average price" query reads everything. A columnar store holds names, prices and quantities as separate columns, with the price column highlighted; it reads only the specific column required from Parquet, keeping data in the CPU cache.

Why is DuckDB so good at analytics while SQLite is so good at transactions? Two choices, one about storage and one about execution, make a big difference. Picture a table of products, each with a name, a quantity and a price.

A row store keeps each row together: the first product with its quantity and price, then the second, and so on. Analytical queries rarely want that shape, though. "Give me the average price of all your products" needs one column out of three. A column store keeps each column together instead, in memory and on disk, so the engine can read just the prices and skip the rest. If rows contain variable-length text, a row store can't even jump a fixed number of bytes to find the price.

Keeping a column together also makes compression easy, because lightweight compression depends on similar values sitting side by side. A column of dates that barely change from row to row compresses nicely with delta encoding. In a row store the value after a date is a price or a string, so there's nothing to work with.

It isn't free. Updating the price of one product is a single lookup in a row store. In a column store the engine first scans one column to find the row, then goes somewhere else to change the price. That trade-off is why SQLite suits transactional work, where one row changes now and then, and DuckDB suits queries that read big chunks of a few columns.

The columnar layout also enables vectorized execution. Instead of pushing one tuple at a time through the query plan, the engine sends batches of values through it in one go, unless something like a join forces a break. Each batch is small enough to sit in the CPU cache, so the engine isn't constantly fetching from main memory. Tuple-at-a-time execution, which is what SQLite does, dates from the 90s, when memory was small, and it tends to cause many cache misses.

Memory limits still matter, though. In the mid-2000s in-memory database systems promised you wouldn't need disk, but memory has limits and people want to run on phones or an Arduino. So DuckDB has real buffer managers and operators that spill to disk, and a query under memory pressure is designed to keep working instead of crashing. DuckDB's blog series on exotic hardware pushes it onto devices like a Raspberry Pi and an iPhone.

“That's why people say that SQLite is good for transactions, and transactions in the sense that it updates one row every now and then. And DuckDB is great for analytics.”

Pedro Holanda

Embedded databases and zero-copy: DuckDB inside your Python process

In-process databases share application memory at constant cost. Overlapping circles for app memory (NumPy array) and database memory (DuckDB vector). "What is a NumPy array? It's literally a C array with some makeup on top. What is a DuckDB vector? It's literally an array with some makeup on top."

Postgres seems to be taking over the database world, yet embedded databases are having a moment too, with SQLite as the best-known example. An embedded (or in-process) database is a library that runs inside your application, so there is no server to provision, secure or keep alive. The database is a file. SQLite does this wonderfully for transactional work, and DuckDB set out to do the same for analytics, though it can run transactions as well.

The idea goes further. DuckDB has a WebAssembly build that runs in the browser, so you can serve a database file from S3 and query it from a web page. There's no server anywhere, and S3 storage is very cheap.

For Python, the bigger payoff is memory. A database inside your process shares your application's memory, so it can avoid copying data around. A NumPy array is a C array with some makeup on top, and a DuckDB vector is an array with some makeup on top too. Change the makeup and both sides can look at the same data at constant cost, with no transformation. Compare that with a client-server database, where a query result has to be copied into a wire format, shipped over a protocol and rebuilt on the other side. Database protocols are slow at moving data, and moving data in and out of a database server was one of the main frustrations seen among data scientists. Running in-process removes that boundary.

In practice you can query a pandas DataFrame, a Polars DataFrame or an Arrow table by using the variable name as the table name:

import duckdb
import pandas as pd
import polars as pl
import pyarrow as pa

prices = pd.DataFrame({'product': ['apple', 'banana'], 'price': [1.0, 2.0], 'qty': [5, 10]})
print(duckdb.sql('SELECT avg(price) FROM prices').fetchall())

pl_df = pl.DataFrame({'x': [1, 2, 3]})
print(duckdb.sql('SELECT sum(x) FROM pl_df').fetchall())

arrow_tbl = pa.table({'x': [1, 2, 3]})
print(duckdb.sql('SELECT max(x) FROM arrow_tbl').fetchall())

# and back out again
print(duckdb.sql('SELECT product, price * qty AS total FROM prices').df())

DuckDB's blog describes its Arrow integration as zero-copy streaming in both directions, so a query can read an Arrow dataset directly and stream results back to Arrow.

Embedded databases have also grown into real application backends. SQLite's write-ahead log cuts down on locking, and Litestream streams changes to an S3 bucket for replication. DuckDB has its own limit here: one process writing to a database file locks other processes out. That's the problem Quack, still experimental, is meant to solve, covered in its own section.

“So you can just change the makeup and then you can suddenly access the same data with constant cost, right? You don't have to transform actual data.”

Pedro Holanda

Data inlining: how DuckLake solves the small file problem

Data inlining solves streaming insert bloat natively. The Iceberg way: 1 insert = 1 tiny data file + 4 metadata files. The DuckLake way: small inserts live in the catalog until enough accumulate to flush a 512MB Parquet file. A funnel drops a Parquet file into the lake. ~1000x faster than raw Iceberg.

Anyone who has run a data lake for a while knows the small file problem. Lots of small inserts, say from a streaming source, create lots of small data files. In Iceberg each insert also writes its own metadata files. Pedro Holanda thinks it's four per insertion, though he's quick to add that he's far from an Iceberg specialist. Reading one snapshot means requesting all of them, and even though each file is tiny, the latency adds up.

DuckLake already handles the metadata half, since its metadata is rows in a database rather than files. On its own it would still leave a pile of tiny Parquet files. Data inlining handles that half. The catalog is a database, and databases are good at storing tables, so small inserts go into a table inside the catalog instead of a new Parquet file. That table has the same columns as your data plus a few DuckLake needs, such as the snapshot that inserted each row and the snapshot that deleted it. When enough rows pile up, they get flushed to a real Parquet file and removed from the inline table. Everything stays transactional and snapshot-aware the whole time.

You control this from SQL. The DATA_INLINING_ROW_LIMIT option on ATTACH sets how many rows still count as small (at the time of writing the docs list a default of 10), and ducklake_flush_inlined_data flushes on demand:

import duckdb

con = duckdb.connect()
con.sql('INSTALL ducklake')
con.sql("ATTACH 'ducklake:catalog.ducklake' AS lake (DATA_PATH 'data/', DATA_INLINING_ROW_LIMIT 100)")
con.sql('USE lake')
con.sql('CREATE TABLE readings (sensor_id INTEGER, temperature DOUBLE, ts TIMESTAMP)')

for _ in range(50):
    con.sql('INSERT INTO readings VALUES (1, 21.5, now())')

# 50 inserts, zero Parquet files: the rows live in the catalog
print(con.sql("SELECT count(*) FROM glob('data/**/*.parquet')").fetchall())
print(con.sql('SELECT count(*) FROM readings').fetchall())

# write them out as one Parquet file
con.sql("CALL ducklake_flush_inlined_data('lake')")
print(con.sql("SELECT count(*) FROM glob('data/**/*.parquet')").fetchall())

Per the docs, small deletes can be inlined too, and a limit of 0 turns inlining off.

What does Iceberg do instead? As Pedro understands it, it leans on separate streaming tools. That could mean another tool to run, and batching may get in the way of having a snapshot per write. In the team's own comparison of raw Iceberg against raw DuckLake on this workload, DuckLake came out roughly a thousand times faster. A loose analogy is Python's file buffering: when you write to an open file, not every byte goes straight to disk, and here the disk is object storage far away.

File sizes in general are up to you. Set a target (512 megabytes with sensible row groups is one example) and DuckLake respects it for batch writes. Many small writes without inlining still produce small files, which is why lakehouse engines offer compaction to merge them. Engines would much rather read one half-gigabyte file, which they can still parallelize, than a thousand 5 KB ones.

“So the idea here is like, well, we are using a database management system. They can store tables.”

Pedro Holanda

Schema evolution and the ducklake-dataframe experiment

Schema evolution without rewriting history. File-based formats: a single schema change fans out to dozens of files; schema changes bloat metadata and slow later reads. DuckLake: a database cylinder reading ALTER TABLE; a million schema changes is just a standard, instant SQL operation.

Schema evolution means changing a table's shape after it has data: adding a column, renaming one, widening a type. In a format built on files, a change like that can mean touching a lot of them. DuckLake supports schema evolution without rewriting any data files, and a schema change is just a SQL operation against the catalog. Every change also becomes a snapshot, so the old schema stays queryable:

ATTACH 'ducklake:catalog.ducklake' AS lake (DATA_PATH 'data/');
USE lake;

CREATE TABLE people (id INTEGER, name VARCHAR);
INSERT INTO people SELECT i, 'person ' || i FROM range(100) t(i);

ALTER TABLE people ADD COLUMN email VARCHAR DEFAULT 'none';
ALTER TABLE people RENAME name TO full_name;
ALTER TABLE people ALTER id SET TYPE BIGINT;

SELECT snapshot_id, changes FROM lake.snapshots();

-- time travel: the table as it was before the ALTERs
DESCRIBE SELECT * FROM people AT (VERSION => 2);

The ALTER TABLE statements change no data. In Iceberg each one writes files, which the DuckLake developers say makes the metadata grow and slows reads over time. Nobody changes a schema a million times in real life, but a benchmark that does exactly that got built anyway. It started as a joke, with a serious point behind it.

The idea was to test the belief that DuckLake is easier to implement than Iceberg, and to show that, despite the name, it isn't tied to DuckDB. The test came out of a frustrating setup experience. Pedro Holanda needed an Iceberg instance to compare against, and getting one running was slow, even with his AI coding agent on the job. So he wondered whether it would be easier to have the agent write a brand new DuckLake implementation. He let it, a few months before recording, when the models weren't as good as they are now. He didn't really review the code, but it had nice numbers, and a look over the tests seemed good enough.

The result is ducklake-dataframe. Its README describes a pure-Python proof of concept for Polars, pandas and PySpark that reads and writes DuckLake catalogs with no DuckDB runtime dependency, and says it was written entirely by Claude Code and isn't meant for production.

Other implementations have appeared since. Firebolt has a closed-source one, Pedro believes, and Hotdata built one on DataFusion. MotherDuck's Spark connector is another. The goal is for people to write their own readers and writers, with DuckDB's extension and the specification on the DuckLake website as the reference.

“despite the name, Duck Lake is not only entangled to DuckDB. It's an open table format.”

Pedro Holanda

Choosing a DuckLake catalog: DuckDB, Postgres or Quack

Choosing your catalog backend: a deployment matrix. DuckDB (in-process): 1 writer, zero config, best for local dev and daily batch loads. Postgres: multi-writer, ~5 TPS, production server, standard production workloads. Quack (client-server): high contention, ~200 TPS, HTTP server, heavy concurrent writes.

A DuckLake keeps its data in Parquet files and its metadata in a catalog, and the catalog can be any SQL database that meets a few basic requirements. So which one? The deciding questions are how many writers you have and how much infrastructure you want to run. The catalog is picked in the ATTACH string, so switching is a one-line change:

-- DuckDB file: one process at a time, zero setup
INSTALL ducklake;
ATTACH 'ducklake:metadata.ducklake' AS my_ducklake;

-- SQLite file: one writer at a time, but several local clients can share it
INSTALL sqlite;
ATTACH 'ducklake:sqlite:metadata.sqlite' AS my_ducklake (DATA_PATH 'data_files/');

-- Postgres: a server, for multi-user lakehouses with remote clients
INSTALL postgres;
ATTACH 'ducklake:postgres:dbname=ducklake_catalog host=localhost' AS my_ducklake (DATA_PATH 'data_files/');

DuckDB, in-process. The catalog is a single DuckDB file, which makes it the lightest option and a popular one for building a lake on your own machine, including as local storage for AI coding agents. The catch is DuckDB's usual one: only one writer can be connected at a time, so several people can't write to the lake together. For one developer or a nightly batch job, that's no problem. It also enables a serverless trick, covered in the frozen DuckLake section.

SQLite. Also a local file, but the DuckLake docs describe it as a fit for several local clients, since DuckLake retries lock conflicts. It's still one writer at a time. MySQL works too, though at the time of recording the DuckLake docs do not recommend it as a catalog because of known issues in DuckDB's MySQL connector.

Postgres. In production, most people the team has seen use Postgres, because it removes the single-writer limit and works the way people are used to. The price is a server to run. Heavy contention is its weak spot: when many writers hit the same table, every conflict sends the application back to retry, as the Quack section explains.

Quack. DuckDB's new client-server protocol, which the team says already works as a DuckLake catalog, handles that contended case far better. It is still experimental, and its first stable release was expected with DuckDB 2.0, about a month and a half after the recording. Over time it may become the default DuckLake catalog.

So where should a newcomer start? With DuckDB in-process, because Postgres means setting up a server first and DuckDB is one line. A DuckDB catalog allows one writer at a time, so a lake with several writers needs Postgres.

“Quack already works with DuckLake as well, but don't run that in production right now, people. Wait a little bit longer.”

Pedro Holanda

Quack: DuckDB's client-server protocol and 200 transactions per second

Quack: handling 200 contended transactions per second. Traditional Postgres retries bounce back to the client over the network; Quack resolves retries on the server. Built entirely on plain HTTP/HTTPS. 200 transactions per second in a high contention environment is almost unheard of for any other open table format.

DuckDB is an embedded database, and that's mostly a feature: it runs on a laptop or inside an ETL job on a single EC2 machine with nothing to operate. The limit shows up when you want to share a database more widely. Inside one process you can open many connections to the same database, but once a writer in one process holds the lock on the file, other processes can't get in. Quack removes that limit by giving DuckDB a client-server mode, at the cost of going back to a client-server architecture.

Trying it takes two terminals. Per the Quack announcement, the server is one call and the client attaches by address:

INSTALL quack;
LOAD quack;

-- terminal 1: start the server
CALL quack_serve('quack:localhost', token = 'super_secret');

-- terminal 2: connect to it
CREATE SECRET (TYPE quack, TOKEN 'super_secret');
ATTACH 'quack:localhost' AS remote;

For production, host it wherever you like, for example on EC2 behind a load balancer. Quack runs over plain HTTP, so there's no custom protocol on top of TCP to build or debug. It does not use SSL by default, so put a TLS-terminating reverse proxy in front of any server exposed beyond localhost.

Where Quack is meant to matter is as a DuckLake catalog, because of how retries work. With Postgres as the catalog, two transactions can conflict on a snapshot ID. The database then has to go back to the application and tell it to recompute the snapshot ID and send its queries again, and all that round tripping makes each retry expensive. With Quack, DuckLake is loaded on the server itself, so the retries happen there with no trip back to the client. In theory the same could be done in Postgres with stored procedures, but DuckLake can't be loaded into a Postgres server the way it can into Quack.

How much does it matter? With about 20 writers under heavy contention, Pedro Holanda's rough figures were around five transactions per second with Postgres and around 200 with Quack. Open table formats were designed for batch processing, writing a big chunk of data to a table once, not for transactional workloads, so 200 transactions per second under high contention is, in the words of the DuckLake team, almost unheard of for any other open table format. Treat the figures as the team's own, at the time of recording, and Quack as experimental.

“we can immediately do the retrials in the server, avoiding this process, right?”

Pedro Holanda

The frozen DuckLake: a read-only data lake almost for free

The 'Frozen DuckLake' pattern: a data lake almost for free. 1. Batch: write locally via in-process DuckDB. 2. Freeze: upload the .duckdb catalog file to S3. 3. Serve: infinite read-only clients query the lake from S3. Laptops point at a .duckdb file in an S3 bucket. No Postgres, no Quack, zero server costs.

What if you didn't run a catalog server at all? A DuckLake whose catalog is a plain DuckDB file needs nothing running anywhere, and that file can live in S3 next to the data. The pattern is nicknamed the frozen DuckLake: update the lake in a batch, then publish the catalog as a read-only file.

Here's how it works:

  1. Pull the catalog down. Updating a DuckLake with a DuckDB catalog means having that file on your machine.
  2. Write the update. Talk to the local catalog file and write the new Parquet data straight to S3. Only the catalog sits locally; the data goes where it always goes.
  3. Upload the catalog. When the write finishes, put the DuckDB file back in S3.

From then on, any number of read-only connections can use that file as the catalog. There's no Postgres and no Quack server to pay for, so the lake costs almost nothing beyond storage. Readers attach with the READ_ONLY option, which DuckDB's catalog rules allow for many processes at once. Here is a local version of the reader side, and any write against it is refused:

import duckdb

con = duckdb.connect()
con.sql("ATTACH 'ducklake:frozen.ducklake' AS lake (READ_ONLY)")
print(con.sql("SELECT count(*) FROM lake.my_table").fetchall())

The catch is that it's built for batch work. A DuckDB catalog still allows one writer at a time, and every update means pulling the file down and pushing it back. It suits workloads like one update per day or a single bulk load of a lot of data. Many writers or frequent small writes call for Postgres or, eventually, Quack. For a nightly job feeding a team of readers, though, a lake with no servers in it is operationally much simpler: the job runs overnight, and in the morning anyone can download the file and ask all the questions they want.

“you can have a data lake almost for free, right? Because your catalog database is just a file in S3, which is very powerful.”

Guillermo Sanchez

Recap: a data lake without a data platform

The Zero-Platform Data Stack. A laptop connects to Open Formats (no vendor lock-in), In-Process Compute (zero-copy speed) and S3 Catalogs (zero server costs). A serious data lake no longer requires a massive platform team: a SQL catalog, plain Parquet and out-of-core embedded compute, run from a laptop.

Managed platforms such as Databricks and Snowflake handle downtime and replication for you. The trade-off, in Guillermo Sanchez's view, is a steep service fee on top of the cloud infrastructure underneath, and a very high level of abstraction if you want control over your stack. These pieces add up to a different deal:

  • Open formats. Public specs for both the table format and the files mean you can, in theory, change engines and vendors later. See DuckLake architecture.
  • In-process compute. DuckDB runs inside your Python process and shares memory with NumPy and pandas instead of copying data through a protocol. See embedded databases and zero-copy.
  • A catalog that can be just a file. A DuckDB catalog uploaded to S3 serves any number of readers with no server running. See the frozen DuckLake.

The bigger options aren't obsolete. When many people write at once, Postgres is the usual answer, and Quack once it is stable. But you can start with far less than a platform and only grow into one if you need it.

Is DuckLake production-ready? DuckLake 1.0 and how to start

DuckLake 1.0 is open and ready for production. A DuckLake 1.0 hub connects to PostHog, Altertable, Firebolt, Polars and Iceberg Compatibility. "It's literally one line, and you have a data lake working." Pedro Holanda.

Is DuckLake ready for production? At the time of recording, the team's answer was yes: they considered it production ready since the 1.0 release in April. Getting there took a deliberate pause: from roughly version 0.4 to 1.0 no new features went in, only bug fixes, and schema changes were allowed only when they fixed a bug. Bug reports still arrive and are still being fixed.

A big share of the 1.0 work went into keeping a long-running lake healthy. A lake that runs for years keeps growing, so the checkpointing functions had to be complete and easy to use: compacting small files, rewriting data files to apply their deletions, removing orphan files and expiring old ones.

What's next? DuckLake 1.1 was expected alongside DuckDB 2.0, again mostly fixes and smaller optimizations. The bigger direction is Iceberg compatibility: reading from and exporting to Iceberg, so nobody is locked into DuckLake. The project also moves at two speeds. The specification is frozen as much as possible and only gets a new release for a real breaking change to the catalog schema, while the DuckDB extension keeps improving on its own schedule, with recent work on how it computes statistics.

Companies are already building on it. PostHog and Altertable build software on DuckLake, and Firebolt is reportedly moving to it too. Polars is a different story: it's one of the dataframe libraries targeted by the ducklake-dataframe experiment.

Ready to try it? The DuckLake website has examples and tutorials, and getting a lake working takes one line. Here's what that looks like from Python, with a local DuckDB file as the catalog. The ATTACH line is the one that creates the lake:

import duckdb

con = duckdb.connect()
con.sql("INSTALL ducklake")
con.sql("ATTACH 'ducklake:my_lake.ducklake' AS my_lake")
con.sql("USE my_lake")

con.sql("CREATE TABLE products (name VARCHAR, price DOUBLE)")
con.sql("INSERT INTO products VALUES ('Apple', 1.0), ('Banana', 2.0)")
print(con.sql("SELECT avg(price) FROM products").fetchall())

Hit a bug? File a GitHub issue with a fully reproducible script that generates the data and shows the problem: the easier it is to reproduce, the faster it gets fixed. Try it at whatever scale suits you, from a pet project holding your own data to the backbone of a software service. And DuckDB 2.0 brings asynchronous I/O, which was expected to make reading from S3, and DuckLake along with it, much faster.

To build up the Python data skills around all this, Talk Python Training has Polars for Power Users and Data Science Jumpstart with 10 Projects.

“We had people use it in production before DuckLake 1.0. And I was always like, cool, cool, cool. What could go wrong?”

Pedro Holanda

Talk Python's Mastodon Michael Kennedy's Mastodon