Qdrant vs Chroma vs pgvector vs Milvus: Best Vector DB

The short answer

Every serious retrieval-augmented generation (RAG) app needs the same thing: store embeddings, then find the most similar ones fast, ideally filtered by tenant, language, or permission. Qdrant, Chroma, pgvector, and Milvus all do that, but they are built for different jobs. If you already run PostgreSQL, start with pgvector. If you are prototyping in a notebook, start with Chroma. If you are shipping a production RAG service on your own servers, Qdrant is the most balanced choice. If you genuinely expect billions of vectors, Milvus is designed for that scale.

If you are new to local models, start with running an open model locally with Ollama and our local RAG tutorial using Ollama and Qdrant.



Source: RAG architecture diagram via Medium

Comparison at a glance

DatabaseBuilt withBest forWatch out for
QdrantRustProduction self-hosted RAG with filtersAnother service to operate
ChromaPython with a Rust corePrototypes and small appsNot built for large-scale production
pgvectorC, as a PostgreSQL extensionTeams already running PostgreSQLSeparate tuning per distance metric; hybrid search needs extra work
MilvusGo and C++Billion-scale, distributed workloadsHeaviest setup of the four

All four are permissively licensed open source: Apache 2.0 for Qdrant, Chroma, and Milvus, and the PostgreSQL License for pgvector.

Qdrant: the balanced production pick

Qdrant is a purpose-built vector search engine written in Rust. Its standout feature is filtering done during the search itself: metadata stored as a JSON payload can restrict results by tenant, language, or publication status while the HNSW graph is traversed, rather than as a wasteful pre-filter or post-filter step. Qdrant's own FAQ confirms it also supports full-text search with BM25, sparse vectors, multi-vectors such as ColBERT, and hybrid search combining dense and sparse retrieval in one query.

That combination is what production RAG usually needs. Pure semantic search misses exact identifiers such as error codes; keyword search misses paraphrases. Qdrant's hybrid search documentation explains how it merges dense and sparse candidates with fusion methods such as RRF, which avoids comparing scores on different scales. It also supports quantization to cut memory use and on-disk storage for larger-than-RAM collections.

Chroma: the fastest way to start

Chroma is the simplest option here, and that is a feature, not an insult. It runs embedded in your Python process or as a single local server, and its cookbook documents chromadb.PersistentClient(path="./chroma_data") for data that survives restarts. It also ships built-in embedding functions, so a prototype can skip wiring an embedding model manually at first.

The trade-off is scale. Independent comparisons place Chroma at prototype scale, with weaker horizontal scalability and multi-tenancy than Qdrant or Milvus. Use it to prove the idea and learn what your retrieval quality looks like, migrating only when measurements tell you to. One security note from Geekflare's test: Chroma ships with no login, so bind it to localhost or a private network before loading real data.

pgvector: the no-new-service option

pgvector turns the PostgreSQL you may already run into a vector store. Version 0.8.0, documented on PGXN, supports exact and approximate nearest neighbor search, single-precision, half-precision, binary, and sparse vectors, and L2, inner product, cosine, L1, Hamming, and Jaccard distances. Its approximate indexes are HNSW and IVFFlat; HNSW offers the better speed-recall trade-off but slower builds and more memory, while IVFFlat builds faster and uses less memory.

The operational win is huge: one fewer system to back up, monitor, and secure, plus ACID transactions, joins, and point-in-time recovery from PostgreSQL itself. The costs are real too. You add an index per distance function you query, hybrid keyword-plus-vector search is not native in the way Qdrant's is, and at very large scale a dedicated engine pulls ahead. Still, for an existing Postgres app under a few million vectors, pgvector is usually the right default.

Milvus: the billion-scale option

Milvus is the distributed, Kubernetes-native choice, built for massive collections, bulk ingestion, and high concurrency, with GPU-accelerated indexing in its full deployment. Its architecture splits work across node types for queries, indexing, and data, which is why it scales further than a single-node engine but is also the heaviest to operate here.

For trying it out, you do not need the full cluster. Milvus Lite is a lightweight local version exposing the familiar pymilvus API through a local .db file, so code written against Lite can move to Milvus Standalone, Distributed, or Zilliz Cloud with minimal changes. Geekflare's test also flagged a security default: its official compose file publishes MinIO on every interface with the default login, so lock that down before any real deployment.

What the benchmarks actually say

In Geekflare's October 2026 test, 100,000 OpenAI embeddings at 1,536 dimensions were loaded into each engine and 1,000 top-10 searches were run with default settings. Qdrant and Weaviate found 99.3% of the true top 10, Weaviate answered fastest at a median of 4.9 ms, while Milvus and pgvector had the lowest recall at their defaults, 94.8% and 95.4%. Raising pgvector's hnsw.ef_search from 40 to 100 lifted it to 98.4% for under 2 ms more per search.

Do not read that as a universal ranking. The MariaDB benchmark, using one million DBpedia embeddings, found very different groupings depending on dataset, versions, and tuning. Defaults matter more than brand names, recall targets change the winner, and you should benchmark your own dimension, filters, and latency budget before committing.



Source: Basic RAG pipeline diagram via Membase

How to try each one in minutes

Qdrant, from its official local quickstart:

docker run -p 6333:6333 -p 6334:6334 \
  -v "$(pwd)/qdrant_storage:/qdrant/storage:z" \
  qdrant/qdrant
pip install qdrant-client

Then connect from Python with QdrantClient(url="http://localhost:6333") and open the dashboard at http://localhost:6333/dashboard.

Chroma, from its cookbook:

pip install chromadb
import chromadb
client = chromadb.PersistentClient(path="./chroma_data")
collection = client.get_or_create_collection("my_docs")

pgvector, from its README, inside PostgreSQL:

CREATE EXTENSION vector;
CREATE TABLE items (id bigserial PRIMARY KEY, embedding vector(3));
CREATE INDEX ON items USING hnsw (embedding vector_cosine_ops);
SELECT * FROM items ORDER BY embedding <=> '[0.1, 0.2, 0.3]' LIMIT 5;

The toy dimension above follows pgvector's README; use your embedding model's dimension in a real table, and add an index for each distance function you actually query.

Milvus Lite, from its PyPI quickstart:

pip install -U "pymilvus[milvus-lite]"
from pymilvus import MilvusClient
client = MilvusClient("./demo.db")

Verdict: pick by your situation, not by the leaderboard

  • Already run PostgreSQL? Use pgvector. Revisit only when latency, recall, or hybrid search measurements say you must.
  • Prototyping this weekend? Use Chroma. Keep it on localhost and migrate when the prototype earns real users.
  • Shipping production RAG on your own servers? Use Qdrant. Its filtering, hybrid search, and quantization cover the cases that break simpler setups.
  • Planning for billions of vectors or heavy concurrent load? Evaluate Milvus properly, with an ops budget to match, starting from Milvus Lite.

The best vector database is the one your team can operate well at your actual scale. Start simple, measure recall and latency on your own data, and let those numbers decide when to move.

Comments

Popular posts from this blog

Open-Source AI Weekly: Bonsai, GigaChat 4 Lead

Claude Claims Proof of Riemann Hypothesis After 167 Years

How to Build an AI Agent with LangGraph in 30 Minutes