A vector database is a database specialized in storing embeddings, the numerical vector representations of text, images, audio, and other data, and in quickly finding the items closest to a given vector. Unlike conventional databases that look up exact matches, it performs similarity search using distance measures such as cosine similarity, and at scale it relies on approximate nearest neighbor (ANN) indexes for speed.
In AI it is a core component of retrieval-augmented generation (RAG), where it retrieves documents relevant to a query and passes them to a large language model. It is also used for semantic search, recommendation, and duplicate detection. Dedicated products include Pinecone, Weaviate, Milvus, Chroma, and Qdrant, while extensions such as pgvector add vector search to existing databases.