Skip to content

Bitcoin accepted at checkout  |  Ships from Laval, QC, Canada  |  Expert support since 2016

Self-Hosted Vector Databases for RAG (2026): Open-Source Comparison

Once an embedding model has turned your documents into vectors, something has to store them and, on every question, find the closest matches fast. That is the job of a vector database — the storage layer at the middle of a self-hosted RAG stack. This compares the self-hostable options, from a one-file SQLite extension you embed in your app to a clustered server, by index types, native hybrid (dense + keyword) search, quantization, and — the detail most comparisons get wrong — whether each is genuinely open source or only “source-available”.

Quick answer

The vector database is the middle of a self-hosted RAG stack: it stores the vectors an embedding model produces and, at query time, finds the closest matches for a local LLM to answer from. This compares 14 self-hostable vector databases by how much infrastructure they need (embedded in your app, a Postgres extension, a single server, or a cluster), their index types, whether they do NATIVE hybrid (dense + keyword) search, quantization, and — the column that matters most for sovereignty — whether the license is genuinely open source or only "source-available". It is sorted by deployment friction, easiest first.

Honest picks for 2026: the lowest-friction starts are sqlite-vec (one SQLite extension), Chroma (pip install), or LanceDB (embedded AND native BM25+vector hybrid); if you already run Postgres, pgvector keeps vectors, metadata and joins in one ACID database. For a production single-binary server with native hybrid search, Qdrant (Rust, Apache-2.0) or Weaviate (BSD-3) are the cleanly-open picks; Milvus and Vespa scale to clusters. License watch — the column these lists usually get wrong: Elasticsearch is NOT open source (every downloadable build is Elastic License / SSPL; its AGPL covers source only) — use OpenSearch (Apache-2.0) as the truly-open drop-in. Redis re-opened its shipped product under AGPLv3 in v8 (network-copyleft applies), and VectorChord is AGPL/ELv2 (an openness downgrade from its Apache-2.0 pgvecto.rs predecessor). And "hybrid" here means native dense+sparse fusion — pgvector, sqlite-vec and FAISS make you fuse it yourself. Free CSV/JSON under CC BY 4.0.

Download CSV Download JSON REST API →

OSI open = genuine open-source license; source-available = usage-restricted (SSPL/BSL/Elastic/RSAL). Hybrid = native dense+sparse fusion, not metadata filtering. ~ = lower-confidence.

DatabaseTypeLangIndexesHybridQuant.LicenseBest for
Chroma (ChromaDB)
Chroma (chroma-core)
embedded-libraryRust core (1.x rewrite) with Python/JS clientsHNSW (SPANN in the distributed/Cloud engine)partialnone (stores full-precision vectors)Apache-2.0
Core is Apache-2.0 (cleanly OSI-open). Hybrid caveat, not license: stable self-hosted OSS does dense + metadata + document $contains/$regex full-text FILTER, not BM25 fusion; native sparse (BM25/SPLADE) + dense RRF 'Search() API' is newly announced and documented Cloud-first — OSS-GA unconfirmed.
fastest 'pip install and go' DX for a RAG prototype; embedded first, scales to a single server later
LanceDB
LanceDB Inc. (built on the Lance columnar format)
embedded-libraryRust (with Python, TypeScript, Rust, Go SDKs)IVF-PQ, IVF-HNSW variants (HNSW), flat/brute-force; disk-based columnar Lance formatyesproduct (PQ), scalar (SQ), binaryApache-2.0
Embedded OSS core is Apache-2.0 and includes native FTS+vector hybrid; LanceDB Cloud/Enterprise are separate proprietary offerings (does not affect the OSS boolean).
embedded multimodal RAG at scale on a laptop or object storage — native Tantivy BM25 + vector hybrid with rerankers, no server to run
sqlite-vec
Alex Garcia (asg017); backed by Mozilla Builders
embedded-libraryC (zero dependencies)flat/brute-force KNN in stable v0.1.9 (2026-03-31); IVF ('experimental, not enabled') + DiskANN only in v0.1.10-alpha pre-releases; no HNSW. vec0 virtual tables with partition & metadata columnsnobinary (bit vectors) + scalar (int8); float32 defaultMIT OR Apache-2.0 (dual)lowest-friction option — add vector search to an existing SQLite/libSQL app with one extension load, no server; brute-force only at GA so best for small/medium corpora
txtai
NeuML (David Mezzetti)
embedded-libraryPythonpluggable ANN backends: Faiss (default), HNSW (hnswlib), Annoy, NumPy brute-force, Torch, pgvector, sqlite-vecyesscalar; product/scalar via the Faiss backendApache-2.0all-in-one embedded RAG/semantic-search framework — native sparse(BM25)+dense hybrid, SQLite content store, pick your ANN backend
pgvector
Andrew Kane
database-extensionCHNSW, IVFFlat, flat/exactnoscalar (halfvec/fp16), binary (bit), plus sparsevec typePostgreSQL License
PostgreSQL License is an OSI-approved permissive (MIT/BSD-style) license — cleanly open.
self-hosters who already run Postgres — keep vectors, metadata, and joins in one ACID database (native BM25 fusion is DIY via tsvector + manual RRF)
VectorChord (vchord)
TensorChord (successor to pgvecto.rs)
database-extensionRust (pgrx)RaBitQ-based IVF, disk-friendly ANN (DiskANN-style); pairs with the vchord_bm25 companion extension for keyword rankingpartialbinary (RaBitQ), scalarAGPL-3.0-only OR Elastic-License-2.0 (dual)
VERIFIED dual AGPL-3.0 OR ELv2 (both VectorChord and the vchord_bm25 companion). license_osi_open=true only because AGPLv3 is genuinely selectable and copyleft-open — NOT permissive, and a real openness downgrade from its pgvecto.rs predecessor (Apache-2.0). The ELv2 option is source-available/non-OSI. Hybrid is 'partial': requires the separate vchord_bm25 extension + manual fusion.
Postgres users who need pgvector-compatible search at larger scale / lower cost via RaBitQ disk indexing — but note AGPL/ELv2 dual licensing, not the permissive Apache-2.0 of pgvecto.rs
Qdrant
Qdrant Solutions GmbH
single-binary-serverRustHNSW (payload-aware / filterable); flat/brute-force for exact searchyesmultiple (scalar, product, binary)Apache-2.0
Core DB (incl. sparse+dense hybrid via the Query API) is Apache-2.0. Some cloud/enterprise features (e.g., RBAC) are proprietary but do not gate the OSS vector+hybrid engine.
purpose-built vector search with rich payload pre-filtering, native sparse(BM25/BM42)+dense fusion (RRF/DBSF), and an easy single-binary self-host
Redis (Query Engine / Vector Sets)
Redis Ltd. (originally Salvatore Sanfilippo / antirez)
single-binary-serverCHNSW and FLAT (brute-force) — used by both the Query Engine vector index and the Vector Sets typepartialscalar int8 (Q8) and binary in the Vector Sets type; classic Query Engine FLOAT32/FLOAT16 vectors are unquantizedTri-license (Redis 8+): AGPLv3 OR RSALv2 OR SSPLv1
VERIFIED. Timeline: BSD-3 → (Mar 2024) dual RSALv2/SSPLv1 source-available, non-OSI → (May 2025, Redis 8.0) AGPLv3 re-added as a third option. license_osi_open=true because — unlike Elasticsearch — AGPLv3 covers the ACTUAL Redis 8 product you build/run, and vector search (Query Engine, formerly the RediSearch module, + the new Vector Sets type) is folded into Redis 8 core under the tri-license. RSALv2 and SSPLv1 remain non-OSI options; pre-8, vector search was a source-available module only. AGPL network-copyleft still applies.
ultra-low-latency in-memory vector search co-located with caching for real-time RAG
Weaviate
Weaviate B.V.
single-binary-serverGoHNSW, flat/brute-force, dynamic (flat auto-upgrades to HNSW)yesmultiple (product PQ, binary BQ, scalar SQ, rotational RQ)BSD-3-Clause
Core is BSD-3-Clause (permissive, cleanly OSI-open) — genuinely open, no source-available trap on the DB core. Native BM25F+dense fusion (rankedFusion/relativeScoreFusion) built in.
developer-friendly native BM25F + dense hybrid search with built-in vectorizer modules
OpenSearch (k-NN plugin)
OpenSearch Software Foundation (Linux Foundation); forked from Elasticsearch by AWS
search-engineJavaHNSW (Lucene / faiss / nmslib engines), IVF (faiss), flat/exact k-NNyesmultiple (byte/scalar, faiss product PQ, binary/BQ, FP16 disk-based)Apache-2.0
Apache-2.0 and now under vendor-neutral Linux Foundation governance (OpenSearch Software Foundation, 2024). THE truly-open, permissive alternative to source-available Elasticsearch — the key sovereignty pick in the ES/OpenSearch split.
Apache-2.0 full search engine + native BM25 + kNN hybrid (normalization processor); the permissive Elasticsearch alternative
Elasticsearch
Elastic N.V.
search-engineJavaHNSW (Lucene), flat/brute-force exact kNN, int8/int4/BBQ-quantized HNSWyesmultiple (int8 scalar, int4, BBQ better-binary-quantization)Elastic License 2.0 / SSPL 1.0 (all downloadable binaries) + AGPLv3 source-only option (added 8.16, 2024)
CORRECTED to FALSE (candidate had true). Every official downloadable distribution is Elastic License 2.0 / SSPL 1.0 — both source-available, NON-OSI. Elastic added an OSI-approved AGPLv3 option in 8.16 (announced 2024) but per Elastic's own licensing FAQ, 'Elastic does not currently offer any downloadable distribution that is covered by the AGPL' — AGPL applies to source code only, so you must self-compile to get an OSI-open build. Practical/mainstream posture remains source-available; contrast Redis 8 (AGPL covers the shipped product) and OpenSearch (clean Apache-2.0).
mature search engine with native RRF hybrid (BM25 + dense kNN + ELSER sparse) at enterprise scale — but source-available licensing; choose OpenSearch if you need a permissive OSI license
Milvus (incl. Milvus Lite embedded mode)
Zilliz / LF AI & Data Foundation
distributed-clusterGo, C++ (Milvus Lite: Python wrapper over the C++ core)Full Milvus: HNSW, IVF (FLAT/SQ8/PQ), DiskANN, SCANN, FLAT, GPU (CAGRA/GPU_IVF), SPARSE_INVERTED_INDEX. Milvus Lite embedded: FLAT + IVF_FLAT (dense) and SPARSE_INVERTED_INDEX (sparse) ONLY — no HNSW/DiskANN locallyyesmultiple (scalar SQ8, product PQ, binary) in full Milvus; limited in LiteApache-2.0
Apache-2.0 across full Milvus and Milvus Lite (same project/repo — the two research-pass rows were deduped into this one entry). Native dense+sparse+BM25 hybrid with RRF is confirmed even in Lite.
billion-scale distributed vector search with the widest index selection and GPU indexing; Milvus Lite gives the same API for embedded local prototyping that lifts to Standalone/Distributed/Zilliz Cloud unchanged
Vespa
Vespa.ai (spun out of Yahoo!)
distributed-clusterJava, C++HNSW (real-time modifiable), multi-vector HNSW, flat/brute-forceyesmultiple (int8, binary/hamming via tensor cell types)Apache-2.0very large-scale hybrid retrieval (text + tensor in one ranking expression) with complex multi-phase ML ranking in a single engine
FAISS (Facebook AI Similarity Search)
Meta (Fundamental AI Research)
library-onlyC++ (with Python/NumPy bindings; some GPU-accelerated)flat, IVF, IVF-PQ, HNSW, LSH, IVF-SQ, PQ/OPQ, IVF-HNSW compositesnoproduct (PQ/OPQ), scalar (SQ), binaryMIT
Not a database — a raw ANN library. db_type intentionally 'library-only'; no persistence/metadata/serving layer of its own.
the raw ANN engine underneath many of the above — maximum index control when you'll build the storage/metadata/serving layer yourself

This is the storage layer of a self-hosted RAG stack. Feed it vectors from a local embedding model (leg 1) and answer with a runtime from the AI runtime comparison (leg 3). Part of D-Central's local-AI knowledge base. Licenses and features change fast — confirm each project's current LICENSE before committing.

That last column is a sovereignty question, not a footnote: Elasticsearch’s downloadable builds are source-available (Elastic License / SSPL), so OpenSearch is the truly-open drop-in, while Redis re-opened its shipped product under AGPL in v8. With the store chosen, complete the stack: vectors from a local embedding model (leg 1) and answers from a runtime in the AI runtime comparison (leg 3). Part of D-Central’s local-AI knowledge base.