VOOZH about

URL: https://memgraph.com/vector-search

⇱ Vector Search in Memgraph


👁 Memgraph
Vector Search

Find similar. Understand connected.

Similarity and structure in a single engine. Run vector search and graph traversal together or use Memgraph alongside your existing vector database.

CALL vector_search.search('movies_index', 5,
$query_vector)
YIELD node, similarity
ONE QUERY
Vector search
[ ... ]
[ ... ]
[ ... ]
Graph traversal
MemgraphONE ENGINE
Result

Modern AI needs both. Memgraph delivers it.

Vector search finds what's semantically similar. Graph traversal finds what's structurally connected. Memgraph handles both in a single engine — with 85% less memory for vector storage.

85%
Memory reduction
(Single Store Index)
HNSW
Powered by
USearch (C++)
3 metrics
Cosine, L2, and
inner product
v3.2+
Production-ready
since Memgraph 3.2
Deployment

Two ways to add graph intelligence
to vector search.

Native vector search in Memgraph

No separate vector database, no data duplication, no synchronization overhead.

  • 👁 Image
    Single Store Vector Index — vectors stored once, not duplicated
  • 👁 Image
    Node and edge vector indexes
  • 👁 Image
    Configurable scalar kinds (f32, f16) for precision/memory trade-off
Best for: teams building new systems who want a single engine for hybrid retrieval.

Memgraph + external vector database

Keep Pinecone, Weaviate, Qdrant, Chroma, or Milvus. Add Memgraph as the graph layer.

  • 👁 Image
    Memgraph handles graph storage and traversal
  • 👁 Image
    Vector DB handles embedding storage and similarity search
  • 👁 Image
    No migration required, add Memgraph to your existing stack
Best for: teams with an established vector pipeline who need to add graph reasoning.
Native search

How it works in Memgraph.

0101

STEP 1. Create a vector index

CREATE VECTOR INDEX movies_index ON :Movie(embedding)
WITH CONFIG {'dimension': 384, 'capacity': 10000, 'metric': 'cos'};
0202

STEP 2. Search by similarity

CALL vector_search.search('movies_index', 5, $query_vector)
YIELD node, similarity
0303

STEP 3. Combine with graph traversal

CALL vector_search.search('movies_index', 5, $query_vector)
YIELD node, similarity
MATCH (node)-[:DIRECTED_BY]->(director)-[:DIRECTED]->(other)
RETURN other.title, similarity
ORDER BY similarity DESC

One query. Both similarity and structure. No external system required.

Benefits

Why this matters for AI workloads.

Retrieval
Hybrid retrieval in one query

Find semantically similar entities, then traverse their relationships to build connected context — in a single pipeline, without round-tripping between systems.

Consistency
No synchronization overhead

When vectors and graph live in the same engine, there's no ETL between databases, no eventual consistency, no data drift between your vector index and your knowledge graph.

Speed
In-memory speed for both

Both vector search and graph traversal run in memory. No disk IO for either operation. Sub-millisecond latency for both.

Decision guide

Which approach is right for you?

01

Use native vector search when:

  • 👁 Image
    Building a new GraphRAG or AI system from scratch
  • 👁 Image
    Eliminating a separate vector database from your stack
  • 👁 Image
    Hybrid queries (vector + graph in one query) matter
  • 👁 Image
    Minimizing operational complexity and memory costs
02

Use Memgraph + external vector DB when:

  • 👁 Image
    You already have a vector database in production
  • 👁 Image
    Specialized features needed (managed scaling, multi-modal embeddings)
  • 👁 Image
    Adding graph reasoning without migrating your vector pipeline
  • 👁 Image
    Separate scaling of vector and graph workloads is a priority
Integrations

Works with your stack.

LangGraph

Memgraph toolkit with 7+ tools for building stateful, multi-actor agent applications with graph-backed state management.

Read docs

LlamaIndex

Create knowledge graphs from unstructured data and query with natural language via Memgraph graph store.

Read docs

LightRAG

Fast retrieval-augmented generation combining graph databases with LLMs for creating and querying knowledge graphs.

Read docs
Get started

Add structure to your search.

© 2026 Memgraph Ltd. All rights reserved.
Terms & Privacy