In this piece
Vector Databases Compared: pgvector, Pinecone, Qdrant, Weaviate
Every retrieval-augmented generation (RAG) product needs somewhere to store embeddings and search them fast. The four names that come up most are pgvector, Pinecone, Qdrant and Weaviate. In this vector database comparison the short answer is that the best choice is the one that fits how you already run data: pgvector if you are on Postgres, a managed service if you want no database operations, and a dedicated open-source engine if you need to self-host search at larger scale. We compare them on what actually separates them in production: license, hosting, hybrid search, filtering and operations. The answer quality of your RAG system depends far more on chunking, hybrid retrieval and evaluation than on the brand of database, so we also cover how to test the choice on your own data before you commit.
We reviewed the external references on 19 November 2026. Vector databases ship features quickly; check the official docs linked below for the current state, and the vendors’ own pages for pricing.
Choosing a retrieval stack for your AI product?
Scope your RAG systemWhat is the difference between pgvector, Pinecone, Qdrant and Weaviate?
They solve the same problem from different starting points. One is an extension to a database you may already run, one is a managed-only service, and two are dedicated engines you can run yourself or rent as a cloud service.
| Product | License | How you run it | Hybrid search |
|---|---|---|---|
| pgvector | Open source (PostgreSQL license) | Extension in your own Postgres or a managed Postgres that offers it | Combine with Postgres full-text search, then fuse results |
| Pinecone | Proprietary | Managed service; bring-your-own-cloud option on the Enterprise plan | Dense, sparse and full-text signals; filter-then-rank or fusion |
| Qdrant | Open source (Apache 2.0) | Self-host, or Qdrant’s managed cloud | Sparse and dense vectors fused in one Query API call (RRF or DBSF) |
| Weaviate | BSD-3 core; some enterprise features under a separate license | Self-host, or Weaviate’s managed cloud | Built-in BM25F plus vector search, weighted with alpha |
pgvector adds vector similarity search to Postgres, with exact search and two approximate index types, HNSW and IVFFlat. Its README recommends using it together with Postgres full-text search for hybrid search, and combining the two result lists with reciprocal rank fusion or a cross-encoder. Embeddings live in the same database as your rows, so joins, transactions, backups and row-level permissions all work as they already do.
Pinecone is a fully managed service; you do not run the engine. Its hybrid search guide describes two patterns: filter and rank in a single request, or separate searches merged with reciprocal rank fusion. For companies that need data in their own cloud account, Pinecone offers bring your own cloud on AWS, Google Cloud and Azure for Enterprise customers.
Qdrant is an Apache 2.0 engine written in Rust. Its Query API runs several sub-queries as prefetches, such as a sparse and a dense query, and fuses them with reciprocal rank fusion (the default) or distribution-based score fusion, in a single request.
Weaviate has hybrid search built in: its hybrid query runs a BM25F keyword search and a vector search and fuses them, with an alpha parameter from 0 (pure keyword) to 1 (pure vector). Note the license: the core is BSD-3-Clause, while code in its enterprise directory needs a separate license key.
When is pgvector enough?
More often than vendor marketing suggests. If your product already runs on Postgres, pgvector removes a whole system: no second database to secure, back up, monitor or keep in sync with your source rows. Multi-tenant filtering is a plain where clause, and the permission model you already trust applies to embeddings too.
create extension if not exists vector;
create table chunks (
id bigserial primary key,
tenant_id uuid not null,
body text not null,
embedding vector(1536) not null
);
-- Approximate index for cosine distance
create index on chunks using hnsw (embedding vector_cosine_ops);
-- Keep filtered queries from returning too few rows (pgvector 0.8.0+)
set hnsw.iterative_scan = relaxed_order;
select id, body
from chunks
where tenant_id = $1
order by embedding <=> $2
limit 8;One trap to know: with approximate indexes, pgvector applies filters after the index scan, so a selective filter can return fewer rows than you asked for. The README’s own example is a filter matching 10% of rows returning only about 4 rows on average with default HNSW settings. Since version 0.8.0, iterative index scans fix this, as in the snippet above. The limits that push teams off pgvector are usually operational: index builds competing with your transactional workload for memory, or a search load you would rather scale separately from your main database.
How do you choose a vector database for RAG?
- Start from your current stack. On Postgres? Try pgvector first. Its cost is close to zero and moving later is a data export, not a rewrite, if your retrieval code sits behind one interface.
- Decide who runs it. No one on the team wants to operate a database: managed (Pinecone, or the managed clouds of Qdrant and Weaviate). Data must stay in your own infrastructure: self-hosted Qdrant or Weaviate, pgvector, or Pinecone’s bring-your-own-cloud on Enterprise.
- Check hybrid search and filters. Real questions contain product codes, names and error messages that pure vector search misses. Make sure the option you pick handles keyword plus vector retrieval and the metadata filters you need, such as tenant, language or document permissions.
- Evaluate on your own data. Build 50 to 200 real questions with known good answers and measure retrieval recall and answer quality on each candidate. Benchmarks published by vendors use their data, not yours.
- Price it on the official pages. Costs depend on vectors stored, dimensions, queries and replicas. Model your volume with each vendor’s current pricing page rather than a blog post’s numbers.

"When a RAG system gives bad answers, the database is almost never the cause. Chunking, missing keyword search and the lack of an evaluation set are. Pick the boring option first and spend the time you save on evaluation."
What matters more than the database?
- Chunking. How you split documents decides what can be found. Keep headings with their text and test a few chunk sizes against your evaluation set.
- Embedding model. Changing the model means re-embedding everything, so store the model name and version with every vector.
- Permissions. Filter by user, tenant or role inside the query, not after it, so the model never sees text the user should not.
- Freshness. Decide how updates and deletions in your source data reach the index, and how quickly. Stale embeddings produce confident answers from documents that no longer exist.
- Re-ranking. A cross-encoder or re-ranking step on the top results often improves answers more than any index tuning.
How Devoun can help: our RAG development work starts with a paid Discovery that picks the retrieval stack against an evaluation set built from your real questions, then builds in fixed-price milestones. A milestone you do not accept is refunded under our money-back guarantee.
Frequently Asked Questions
Which vector database is best for RAG?
There is no single best one. If you already run Postgres, pgvector is usually the simplest start. If you want no database operations at all, a managed service such as Pinecone fits. If you need to self-host a dedicated engine, Qdrant and Weaviate are the common open-source choices. Choose with an evaluation on your own data.
Is pgvector good enough for production?
For many products, yes. It supports approximate indexes (HNSW and IVFFlat), keeps vectors in the same database as your rows and permissions, and works with Postgres full-text search for hybrid retrieval. Test recall and latency on your own data volume before you commit.
Which vector databases are open source?
pgvector (PostgreSQL license) and Qdrant (Apache 2.0) are open source. Weaviate’s core is BSD-3-Clause, with some enterprise features under a separate license. Pinecone is a proprietary managed service.
Do I need hybrid search?
Usually, yes. Pure vector search misses exact terms such as product codes, names and error messages. Combining keyword and vector results, for example with reciprocal rank fusion, is a common default for RAG.
Final thoughts
pgvector, Pinecone, Qdrant and Weaviate are all credible choices in 2027. The decision mostly comes down to who operates the database and where your data must live. Start simple, keep retrieval behind one interface, and let an evaluation on your own questions, not a feature table, tell you when to move.