VibeSQL

A pure-Rust SQL database
built for speed

VibeSQL trades storage efficiency for performance. Hybrid row + columnar storage, vectorized execution, and zero unsafe code. Optimized for datasets that fit in memory.

SQL:1999 compliant. Runs natively, in WebAssembly, and as an embedded library.

Why VibeSQL?

Hybrid Storage

Both row and columnar storage in one engine. Row format for fast point lookups and OLTP. Columnar format for analytical scans with vectorized execution. No need to choose.

Speed Over Storage

Deliberately trades disk space for query performance. Redundant storage layouts, aggressive caching, and precomputed indexes mean smaller databases run as fast as possible.

Pure Rust, Zero Unsafe

Written entirely in safe Rust. No C dependencies, no FFI, no unsafe blocks. Compiles to native binaries and WebAssembly from the same codebase.

Architecture

Query Pipeline

1 Parser — Full SQL:1999 grammar, arena-allocated AST
2 Planner — Cost-based optimizer with join reordering
3 Executor — Vectorized execution with batch processing
4 Storage — Hybrid row/columnar with B-tree indexes

Key Features

  • Window functions (ROW_NUMBER, RANK, LEAD/LAG, NTILE, ...)
  • Common Table Expressions (WITH, recursive CTEs)
  • Subqueries (correlated, EXISTS, IN, scalar)
  • Full JOIN support (INNER, LEFT, RIGHT, FULL, CROSS, NATURAL)
  • Triggers, views, foreign keys, CHECK constraints
  • WASM target with OPFS persistent storage
--
TPC-H Queries Passing
Decision support benchmark
--
SQLLogicTest Pass Rate
6M+ test assertions
--
TPC-DS Queries Passing
Complex analytics benchmark

Benchmarked against SQLite, DuckDB, and MySQL on equivalent workloads. See full results.

Get Started