DuckDB Spatial & Modern Analytical SQL for GIS

Production-grade reference documentation for in-process spatial SQL: run geospatial analytics directly inside DuckDB with vectorized, columnar execution — no GIS server, no row-by-row round trips.

These guides target data engineers, GIS analysts, and Python developers who need deterministic performance at scale. You'll find the execution model behind DuckDB Spatial, the query patterns that keep spatial joins and aggregations vectorized, and the integration paths that move geometries between SQL and Python without serialization overhead.

Every page is grounded in real configuration: memory limits and spill thresholds, CRS handling, GeoParquet and GeoJSON ingestion, execution-plan validation, and a full migration track for teams moving off PostGIS or GeoPandas — function-by-function translation, index porting, and the benchmarks that mark the performance crossover.

The reference now runs to 82 pages across 4 tracks and 24 topics, including geometry validity and repair, partitioning and file layout for spatial lakes, Python UDFs and predicate pushdown, and head-to-head comparisons against PostGIS, GeoPandas and Sedona.

Explore the reference

Four tracks, from engine internals to query craft to Python pipelines and PostGIS/GeoPandas migration.

DuckDB Spatial Architecture & Fundamentals

The execution model: vectorized columnar processing, GeoParquet/GeoJSON ingestion, CRS handling, spatial indexing internals, and in-memory vs disk tradeoffs.

Open section

Python & DuckDB Integration Workflows

Zero-copy Python integration: async execution, batch pipelines, Shapely interop, and efficient DuckDB → GeoPandas synchronization.

Open section