Stop Guessing Your Vector DB Size: The Production Sizing Field Guide for 4 Million Passages Engineers at Databricks benchmarked vector and hybrid search across 1, 2, and 4 million MIRACL Wikipedia passages using 1024-dimensional gte-large-en-v1.5 embeddings, finding that ANN index structures add roughly 40% overhead over raw float arrays, or about 5.75 GB per million passages. The measurements show latency turning bimodal when the local file cache ratio falls too low, and that lowering the candidate retrieval limit from the tutorial default of 1,000 to 200 roughly halves cold query latency. Stop Guessing Your Vector DB Size: The Production Sizing Field Guide for 4 Million Passages What Databricks measured across 4 million Wikipedia passages: how to calculate index memory per million vectors, why cache ratios dictate latency, and why 200 candidates beat 1,000. When engineering teams build their first Retrieval-Augmented Generation RAG prototype, sizing the vector database is rarely a priority. You embed 50,000 documentation chunks, spin up a small Postgres instance with pgvector or a starter Qdrant node, and run similarity queries. Results come back in 8 milliseconds. Then you roll the system out to production data. You ingest 4 million passages across internal wikis, support tickets, and product catalogs. Within hours, search latency turns erratic: half your queries return in 10 milliseconds, while the other half stall for 200 milliseconds. You double the database instance size, yet throughput barely budges while your cloud bill quadruples. The problem is rarely the vector database engine itself. Most teams run into trouble because they size vector search by trial and error. They do not calculate index memory expansion on disk, they ignore the ratio between local file cache RAM and index size, and they leave candidate retrieval limits at the tutorial default of 1,000. Recently, engineers at Databricks published a detailed empirical benchmark measuring vector and hybrid search across 1 million, 2 million, and 4 million passages from the MIRACL English Wikipedia corpus using 1024-dimensional embeddings gte-large-en-v1.5 . Their data gives us concrete numbers for how vector indexes grow, why latency turns bimodal under memory pressure, and how a single parameter tweak cuts cold query latency in half. How Fast Does a Vector Index Actually Grow? To size a vector store properly, you first have to separate the raw table data your text chunks and metadata columns from the approximate nearest neighbor ANN vector index structure. In Databricks’ tests, every passage was embedded into a 1024-dimensional float vector the same dimensionality used by many commercial and open-source large embedding models . Storing one million raw 1024-dimensional float32 vectors takes roughly 4.1 GB 1,000,000 1024 4 bytes . Once you build a navigable graph or quantized proximity index over those vectors, the index structure adds roughly 40% overhead on top of the raw float arrays: Notice how cleanly linear that growth is. For 1024-dimensional embeddings, you can rely on a straightforward rule of thumb: budget roughly 5.75 GB of index footprint per million passages , completely separate from your relational text tables and B-tree indexes. If you are planning a 10-million-passage corpus, your vector index alone will occupy around 57.5 GB. The Cache Ratio Rule: Why Latency Jumps From 4ms to 187ms A common misconception in vector search is that you must buy an enormous in-memory server that pins 100% of your database in active process memory at all times. Modern disk-backed and page-cached engines do not require pure in-memory storage, but their performance is governed by a single ratio: the Local File Cache Ratio . When a database traverses an ANN graph to answer a similarity query, it reads 8 KB pages. Because a 1024-dimensional float32 vector takes 4 KB on its own, a single 8 KB database page holds only one or two vectors plus graph neighbor pointers. A single query inspecting a few hundred candidate nodes touches hundreds of distinct 8 KB pages scattered across the index. If those pages are sitting in local RAM cache, fetching them takes microseconds. If they miss the cache, the engine has to stall on hundreds of random disk or remote storage reads. Databricks measured query latency across different cache ratios on the 4-million-passage index, and the cliff is dramatic: - At a Cache Ratio of 0.07 severe RAM starvation : 93% of page lookups miss the local cache and hit cold storage. Median warm vector search latency sits at 187 milliseconds . - At a Cache Ratio of 0.3 to 0.7 partial caching : Latency turns bimodal . Queries hitting frequently accessed clusters return in 6 milliseconds, while queries traversing uncached regions of the graph spike to 180 milliseconds. In an agent loop that runs five sequential retrieval calls per turn, a 50% cache-miss rate guarantees at least one or two slow stalls on every single user prompt. - At a Cache Ratio of 1.0 or higher cache matches index size : 96% to 98% of page reads hit local memory, and median warm latency drops to 4 milliseconds . Even more revealing: once your Cache Ratio reaches 1.0 , search latency stays flat as your dataset grows . Searching 4 million passages with a 1.0 cache ratio took the same 11 to 23 milliseconds as searching 1 million passages. Corpus size only slows down queries when your cache ratio falls below 1.0 and forces disk I/O. Why 200 Candidates Beat 1,000 Almost every vector search SDK and tutorial includes a parameter governing how many candidate vectors the ANN search inspects before returning your final top-10 results often named ef search , probes , or candidate limit . And almost every boilerplate code snippet sets that number to 1,000 . Databricks benchmarked what actually happens when you drop the candidate pool from 1,000 down to 200 when retrieving the top 10 passages: - Two-thirds fewer page reads: Inspecting 200 candidates instead of 1,000 reads only one-third as many 8 KB pages from the index. - 50% faster cold queries: When queries do miss the cache and hit storage, cutting the candidate pool to 200 slashes cold search latency in half. - 90.5% overlap in top-10 results: Despite doing one-third of the work, a 200-candidate search returned 90.5% of the exact same top-10 passages as a 1,000-candidate search. If you pair that with a higher-quality index build configuration during ingestion for instance, using high-precision quantization or higher build-time graph connectivity rather than compensating at query time with massive probe counts , you get better recall at a fraction of the per-query I/O cost. In Databricks’ tests, building the index in quality mode raised baseline Recall@10 from 0.74 to 0.80 at 3 milliseconds, and reached 0.91 recall at 500 probes in less than half the query time of a standard index. When Scaling the Database Stops Helping: The Python Worker Bottleneck One of the most useful findings in the Databricks benchmark had nothing to do with vector math. It happened during concurrency load testing. The team scaled the database tier from 1 Compute Unit CU up to 16 CUs under continuous query load. From 1 CU to 8 CUs, throughput scaled cleanly. Going from 8 CUs to 16 CUs , however, doubling the database hardware produced only a 4% gain in query throughput . When throughput plateaus like that in production, the knee-jerk reaction is to blame the vector index. In reality, the database CPU at 16 CUs was sitting mostly idle. The bottleneck had moved into the Python application tier : the worker processes issuing queries and parsing JSON responses were saturated on connection pooling and serialization. Before upgrading a vector database node, always verify that database CPU utilization is actually crossing 60%. A Practical Vector Sizing Calculator in Python Before provisioning hardware for a new RAG or semantic search workload, you can estimate your index footprint, required page-cache RAM, and concurrency budget with a quick back-of-the-envelope script: python from typing import Dict, Union def estimate vector search footprint num passages: int, embedding dim: int = 1024, bytes per float: int = 4, ann overhead multiplier: float = 1.40, - Dict str, Union int, float, str : 1. Raw float array size in GB raw bytes = num passages embedding dim bytes per float raw gb = raw bytes / 1024 3 2. ANN graph / index footprint on disk ~5.75 GB per 1M at 1024d index gb = raw gb ann overhead multiplier 3. Target local file cache RAM for Cache Ratio = 1.0 +15% OS buffer headroom target cache ram gb = index gb 1.15 return { "passages": f"{num passages:,}", "raw vectors gb": round raw gb, 2 , "ann index gb": round index gb, 2 , "recommended cache ram gb": round target cache ram gb, 2 , "recommended candidate pool": 200, } Sizing a 4-million-passage corpus with 1024-d embeddings: print estimate vector search footprint 4 000 000, embedding dim=1024 {'passages': '4,000,000', 'raw vectors gb': 15.26, 'ann index gb': 21.36, 'recommended cache ram gb': 24.57, 'recommended candidate pool': 200} Sizing by Physics, Not Folklore Vector search does not have to be a mysterious black box that eats cloud budgets. The rules that govern latency at scale are straightforward: - Budget roughly 5.75 GB of index space per million 1024-dimensional vectors . - Provision enough local file-cache memory to keep your Cache Ratio at or above 1.0 , which holds warm search latency flat in the single-digit milliseconds whether you have 1 million or 10 million passages. - Drop your query candidate pool from 1,000 to 200 and invest in index build quality instead of brute-force query probes to cut cold page reads by two-thirds while preserving over 90% top-10 overlap. When your cache ratio is right and your candidate pool is bounded, a 14-minute load test serving 109,000 vector queries in Databricks’ benchmark cost just $0.02 in compute . Good capacity planning is still the best latency optimization money can buy. Further Reading & Resources - Databricks Blog: Sizing Lakebase Search: Lessons from a Real App and 4 Million Passages https://www.databricks.com/blog/sizing-lakebase-search-lessons-real-app-and-4-million-passages : The full empirical benchmark covering 1M, 2M, and 4M MIRACL passage workloads. - MIRACL Benchmark Dataset https://project-miracl.github.io/ : The Wikipedia passage retrieval benchmark used in the sizing experiments. - pgvector Documentation https://github.com/pgvector/pgvector : Open-source vector similarity search for PostgreSQL, including HNSW and IVFFlat index tuning parameters. - gte-large-en-v1.5 Model Card https://huggingface.co/Alibaba-NLP/gte-large-en-v1.5 : The 1024-dimensional embedding model evaluated in the benchmark.