DuckDB-WASM GIS
DuckDB-WASM is GeoLab's execution engine, not a remote backend. A Web Worker owns the database connection, the Spatial extension executes geometry SQL, and query results are converted into browser map buffers.
- Engine
- DuckDB-WASM AsyncDuckDB
- Isolation
- Web Worker
- Extension
- DuckDB Spatial
- Rendering
- Arrow/WKB to deck.gl binary data
Execution chain
- Select a compatible DuckDB-WASM bundle and start its worker.
- Instantiate AsyncDuckDB, open a connection, then INSTALL and LOAD spatial.
- Register selected files in the WASM file system and create local DuckDB tables.
- Run SQL through the asynchronous connection.
- Convert point columns or WKB geometry into deck.gl binary attributes for rendering and picking.
The initialization self-check
GeoLab verifies that the Spatial extension can construct and serialize a geometry before declaring the local engine ready.
SELECT ST_AsText(ST_Point(1, 2)) AS spatial_self_check;NoteThe expected value is POINT (1 2). A failure closes the connection and surfaces an engine-start error instead of silently disabling spatial functions.
What runs locally and what still uses the network
| Operation | Location |
|---|---|
| File registration and SQL execution | Browser / DuckDB-WASM |
| GeoLab application backend upload | None |
| CARTO basemap tiles | External network request |
| Spatial extension initialization | May require a network download |
System boundary
- The current application loads only the Spatial extension; it does not promise every DuckDB extension works in the browser.
- There is no server-side concurrency, user account, cross-device state, or durable database file.
- Large results remain subject to browser memory and GeoLab's spatial render limit.
Sources and scope
These links document the product behavior summarized above. GeoLab-specific claims are limited to the current public v0.1.0 implementation.
- DuckDB-WASM overviewOfficial browser client architecture and platform scope.
- DuckDB Spatial documentationOfficial overview of the Spatial extension used by GeoLab.
- GeoLab engine implementationBundle selection, worker setup, extension load, import, and query paths.