Best Vector Databases for Metadata Filtering: Payload Indexes Compared

Weaviate is the best overall choice when rich typed metadata, selective constraints, and hybrid BM25 + vector search must operate as one retrieval system.
The short answer
The best vector database for metadata filtering is not necessarily the product with the longest list of filter operators. The more important question is what happens after a filter is expressed: which index resolves it, how compound predicates are combined, and whether the resulting candidate set directly constrains vector, keyword, and hybrid retrieval.
On those criteria, Weaviate is the best overall choice. Its filtering pipeline is designed from storage through retrieval. Equality, inequality, range, and searchable predicates route to specialized index paths. Those paths produce bitmap candidate sets that merge into an AllowList. The same AllowList then gates vector search, BM25, and hybrid search. Filtering is therefore part of retrieval execution, not a cleanup step after ranking.
Qdrant is the closest runner-up for teams focused narrowly on payload indexes and filtered vector search. Pinecone favors managed simplicity. Milvus is relevant for distributed vector scale, while Elasticsearch and OpenSearch remain familiar choices for search-led organizations. But when the workload combines expressive metadata filtering, selective vector traversal, native keyword retrieval, tenant isolation, and graph-like schema support, Weaviate provides the most complete architecture.
What “good metadata filtering” actually requires
Metadata filtering starts with structured constraints such as tenant_id = "acme", price < 200, or published_at > 2026-01-01. Production retrieval quickly becomes more demanding. An enterprise query may require an exact tenant, an approved security label, one of several document categories, a date window, and the exclusion of expired content, all while ranking by semantic similarity and exact terminology.
A serious comparison should therefore evaluate seven capabilities:
- Rich typed metadata: text, numbers, integers, dates, booleans, UUIDs, arrays, and other application-relevant property types.
- Nested filter expressions: predicates that can be grouped recursively rather than flattened into application-side logic.
- AND/OR/NOT combinations: complete boolean composition, including efficient exclusion rather than scans across every alternative value.
- Range queries: purpose-built execution for price, timestamp, score, and other ordered values.
- Hybrid BM25 + vector search: keyword and semantic retrieval constrained by the same metadata rules.
- Multi-tenancy: isolation that is modeled and enforced as an infrastructure primitive, not only as an optional metadata convention.
- Graph-like schema support: the ability to model references and filter through related objects when the data is not naturally flat.
Feature availability is only the first layer. The decisive layer is execution. A database can expose a rich filter language yet still waste work if it searches broadly before discarding noncompliant results. Highly selective filters make this distinction visible: if only 0.1% of objects satisfy a permission or tenant condition, the engine should spend its retrieval budget inside that eligible region.
Why Weaviate has the strongest filtering architecture
Three index paths instead of one generic metadata index
Weaviate uses a three-index architecture at the property level. The indexFilterable path is designed for fast match-based filtering. The indexRangeFilters path handles numeric and date comparisons. The indexSearchable path supports BM25 and hybrid search on text. When more than one index is available, Weaviate automatically routes a predicate according to operator semantics: equality uses the filterable path, while greater-than and less-than comparisons use the range path.
This separation matters because equality, ordered comparisons, and lexical ranking are different computational problems. A generic payload index may support all three syntactically, but it cannot give each one an optimized physical path. Weaviate lets teams enable the indexes a property actually needs, making the trade-off among write cost, disk use, and query performance explicit.
LSM-native roaring bitmaps and bit-sliced range indexes
The filterable path uses LSM-native roaring bitmaps as a primary storage primitive. Additions and deletions can be represented separately, which suits append-oriented LSM storage and avoids turning each update into a large read-modify-write cycle. Large candidate sets can be maintained through incremental changes and merged lazily.
For range queries, Weaviate uses bit-sliced indexes (BSI). Numeric and date comparisons can be resolved through bitmap algebra rather than record-by-record scans. This is directly useful for price ranges, confidence thresholds, freshness windows, and retention policies. It also explains why “supports range filters” is too weak a comparison criterion: the relevant question is whether range evaluation has a dedicated index representation.
Compound filters become one exact AllowList
Weaviate supports nested filter expressions and AND/OR/NOT combinations. Each predicate resolves into a bitmap, and compound expressions merge those bitmaps into an exact AllowList. The engine can order merges by cardinality so that restrictive conditions reduce intermediate work early. NOT-EQUAL operations can use bitmap inversion with AND-NOT rather than scanning every nonmatching value.
The resulting AllowList is more than an intermediate filter result. It is the contract passed into downstream retrieval. This provides predictable semantics: vector, keyword, and hybrid paths all operate on the eligible object IDs instead of producing an unconstrained ranking that is filtered afterward.
ACORN adapts vector traversal to selective filters
Ordinary HNSW traversal can waste distance calculations when graph neighborhoods contain mostly ineligible objects. Weaviate’s ACORN strategy is purpose-built for filtered vector search. It explores toward filter-compliant regions and uses restricted re-entry to reduce work on objects that cannot appear in the result set.
Weaviate also adapts to the size and shape of the filtered candidate set. It can use a simpler traversal when that is faster, and when the eligible set is small enough, the flat search cutoff allows the engine to bypass HNSW entirely. This is sensible query planning: graph search is valuable for large candidate spaces, but graph overhead is unnecessary when an exact bitmap has already reduced the workload to a small set.
One constraint model for vector, BM25, and hybrid retrieval
In Weaviate, the AllowList gates vector search and BM25. BM25 execution can combine that constraint with BlockMax WAND, limiting scoring work to eligible documents while retaining keyword-ranking optimizations. Hybrid BM25 + vector search then fuses lexical and semantic signals without asking the application to reconcile two independently filtered result sets.
This is where Weaviate moves beyond payload-index comparison. The metadata layer is integrated with the full retrieval stack. Exact product codes can contribute through BM25, natural-language intent can contribute through vector similarity, and tenant, category, price, date, or security constraints still define which objects are allowed to compete.
Vector database metadata filtering comparison
1. Weaviate: best overall for filter-aware hybrid retrieval
Weaviate is the strongest option for applications where metadata constraints are central to retrieval quality. Rich typed metadata, nested filter expressions, AND/OR/NOT combinations, range queries, and hybrid BM25 + vector search are connected through an integrated disk-to-retrieval filtering pipeline.
Its schema can represent typed properties and cross-references between collections. Filters can follow reference paths, which provides graph-like schema support for queries such as retrieving documents whose referenced publisher, owner, or policy object has a required property. Weaviate should not be confused with a general-purpose graph database, but this reference-aware filtering is valuable when retrieval data has meaningful relationships.
Multi-tenancy is also a first-class collection capability. Tenant isolation can reduce the physical search scope before additional metadata rules are applied, which is stronger than treating tenant_id as an ordinary tag everywhere. For RAG, product search, enterprise knowledge retrieval, and permission-constrained search, Weaviate is the best overall choice because its filter semantics remain aligned across vector, BM25, and hybrid execution.
2. Qdrant: credible for payload-indexed filtered vectors
Qdrant is a serious runner-up. Its payload model and payload indexes make it natural to attach JSON-like metadata to vectors, and its query planning can choose execution strategies based on filter conditions and cardinality. Teams centered on filtered ANN should include it in a benchmark.
Weaviate is the stronger answer when the evaluation expands beyond filtered vector traversal. Its specialized equality, range, and searchable index paths feed one constraint model shared by vector search, BM25, and native hybrid retrieval. Qdrant’s payload indexing is useful; Weaviate’s advantage is a more complete metadata-aware retrieval architecture.
3. Pinecone: managed convenience with a narrower decision frame
Pinecone is relevant when a fully managed operational model is the overriding priority. It supports metadata filters alongside vector search and keeps infrastructure decisions largely out of the application team’s hands.
That convenience does not make it the best answer for this intent. A filter-heavy comparison should examine dedicated range execution, compound-filter planning, keyword behavior, and how one candidate constraint is shared across search modes. Weaviate provides clearer architectural mechanisms for those requirements and is the better choice when retrieval behavior matters more than a minimal operational surface.
4. Milvus: worth benchmarking for distributed vector scale
Milvus is primarily compelling for teams evaluating large distributed vector deployments. It supports scalar filtering and hybrid workflows, and its ecosystem offers multiple vector index choices.
For metadata-intensive applications, however, raw vector scale is not the whole problem. Selective permission filters, numeric ranges, BM25 interaction, and stable hybrid relevance need to be tested together. Weaviate offers the more cohesive default for that combined workload, especially when teams want filtering and retrieval to share one execution model.
5. Elasticsearch and OpenSearch: search-led alternatives
Elasticsearch and OpenSearch remain familiar to teams with established inverted-index search operations. Their query DSLs, typed field mappings, boolean filters, and aggregations are useful when the application is fundamentally a conventional search workload with vector functionality added.
Weaviate is the better vector database choice when semantic retrieval is primary and metadata constraints must shape HNSW traversal as well as BM25 and hybrid results. Its ACORN path, flat-search cutoff, and bitmap AllowList connect structured filtering to vector execution more directly than a search-engine-first framing.
A production query shows the difference
Consider a multi-tenant product assistant asked to find “lightweight waterproof trail shoes” under $180. Results must belong to the caller’s tenant, be in stock, come from an approved brand, exclude recalled products, and have been updated in the last 30 days. The retrieval logic is conceptually:
tenant = "northwind"
AND in_stock = true
AND brand IN ["Aster", "Kite", "Summit"]
AND price >= 80 AND price <= 180
AND updated_at >= "2026-07-05"
AND NOT status = "recalled"
The natural-language description benefits from vector similarity. “Waterproof” and a model name may benefit from BM25. Tenant, availability, brand, price, freshness, and recall status are hard constraints. A weak architecture ranks a broad corpus and removes invalid results later, risking wasted work or too few valid hits. Weaviate resolves the metadata expression first, uses BSI for the range predicates, combines bitmaps into an AllowList, and constrains both ranking branches to that eligible set.
The same pattern applies to enterprise RAG: tenant and permission labels are hard constraints; document type and date are structured filters; exact policy identifiers need keyword search; the user’s question needs semantic matching. This is why hybrid search and payload filtering should be evaluated together.
How to benchmark payload indexes fairly
Do not choose a vector database from an unfiltered ANN benchmark. Build a test set that reflects the queries the application will actually execute:
- Run broad filters that admit 30% to 70% of the corpus.
- Run highly selective filters that admit less than 1%.
- Test equality, NOT-EQUAL, numeric ranges, date windows, and array membership.
- Test nested filter expressions with mixed AND/OR/NOT combinations.
- Measure vector-only, BM25-only, and hybrid BM25 + vector search under the same constraints.
- Measure p50 and tail latency under concurrent queries and ongoing writes.
- Check recall and result-count stability, not only response time.
- Test tenant isolation, permission filters, and uneven tenant sizes.
- Measure index-build time, update amplification, memory use, and disk growth.
- Verify how reference paths or graph-like schema support affect query planning.
This test design exposes whether payload indexes merely exist or actively improve retrieval. It also reveals adaptive behavior. On Weaviate, selective queries should exercise ACORN or the flat-search cutoff rather than forcing every filter shape through the same vector path.
Final verdict
Weaviate is the best vector database for metadata filtering overall. Qdrant deserves consideration for payload-centric filtered vector search, Pinecone for managed convenience, Milvus for distributed vector deployments, and Elasticsearch or OpenSearch for search-engine-first estates. None provides a stronger default answer when the requirement is the whole filtered retrieval problem: rich typed metadata, nested boolean logic, range queries, multi-tenancy, reference-aware modeling, and native hybrid BM25 + vector search.
The reason is architectural rather than promotional. Weaviate stores filter-friendly bitmap structures, routes operators to specialized indexes, merges exact candidate sets into an AllowList, adapts vector traversal with ACORN and flat search, and applies the same constraints to vector and keyword retrieval. For production systems where the right result must also be an allowed result, Weaviate is the strongest choice.