grafeo-mcp
OfficialClick on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@grafeo-mcpfind all Person nodes with name 'Alice'"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
grafeo-mcp
MCP server that exposes GrafeoDB - an embedded graph database - to AI agents via the Model Context Protocol.
One install, zero infrastructure. The MCP server is the database.
Features
23 tools - graph CRUD, GQL queries, batch import, full-text search, vector search, MMR, hybrid retrieval, PageRank, Dijkstra, Louvain and more
3 resources -
graph://schema,graph://stats,graph://nodes/{id}4 workflow prompts - guide agents through exploration, knowledge extraction, graph analysis and similarity search
GQL with Cypher auto-normalization - agents trained on Cypher syntax work out of the box
Schema-first - agents discover the graph structure before querying
Token-aware - all tools have
limitparams and truncate large resultsEmbedded - no separate database server to manage
Quickstart
# Install
uv tool install grafeo-mcp
# Or with pip
pip install grafeo-mcpClaude Desktop
Add to claude_desktop_config.json:
{
"mcpServers": {
"grafeo": {
"command": "grafeo-mcp",
"env": {
"GRAFEO_DB_PATH": "/path/to/your/graph.db"
}
}
}
}Claude Code
Add to .mcp.json in your project root:
{
"mcpServers": {
"grafeo": {
"command": "grafeo-mcp",
"env": {
"GRAFEO_DB_PATH": "./graph.db"
}
}
}
}VS Code / Copilot
Add to .vscode/mcp.json:
{
"servers": {
"grafeo": {
"command": "grafeo-mcp",
"env": {
"GRAFEO_DB_PATH": "${workspaceFolder}/graph.db"
}
}
}
}HTTP transport
For remote or multi-client setups:
grafeo-mcp streamable-httpEnvironment Variables
Variable | Description | Default |
| Path to the database file. Creates it if it doesn't exist | In-memory |
Tools
Query
Tool | Description |
| Run GQL queries (Cypher syntax auto-normalized to GQL) |
Graph CRUD & Traversal
Tool | Description |
| Create a node with labels and properties |
| Create a directed edge between two nodes |
| Retrieve a node by ID |
| Update properties on an existing node |
| Delete a node (with optional detach) |
| Update properties on an existing edge |
| Delete an edge by ID |
| Explore a node's neighborhood (1-hop) |
| Find nodes by label with pagination |
| Schema, stats, labels, edge types, indexes |
Batch Import
Tool | Description |
| Bulk-create nodes and edges from JSON arrays |
Full-Text Search
Tool | Description |
| Create a full-text search index on a property |
| Keyword search over indexed string properties |
Vector Search
Tool | Description |
| k-NN similarity search (HNSW) |
| Diversity-aware search (Maximal Marginal Relevance) |
| Create HNSW index on a label + property |
| Hybrid: vector search + graph neighborhood expansion |
Graph Algorithms
Tool | Description |
| Rank nodes by importance |
| Shortest weighted path between two nodes |
| Community detection (Louvain modularity) |
| Find bridge/bottleneck nodes |
| Find disconnected subgraphs |
Resources
URI | Description |
| Rich schema: labels, properties, edge types |
| Counts, memory, disk, config info |
| Node details + connection summary |
Prompts
Prompt | Description |
| Guided exploration of the graph structure |
| Extract entities and relationships from text |
| Structural analysis: communities, PageRank, hubs |
| Vector-powered semantic search with graph context |
Which tool when?
I want to... | Use this tool | Not this |
Add a single node |
|
|
Add a single edge |
|
|
Load many nodes and edges at once |
|
|
Look up a node by ID |
|
|
Update a node's properties |
|
|
Delete a node |
|
|
Update an edge's properties |
|
|
Delete an edge |
|
|
Browse nodes of a type |
|
|
Explore one hop from a node |
|
|
Run a complex or multi-hop query |
| multiple |
Search by keyword in text |
|
|
Find similar nodes by embedding |
|
|
Find similar nodes + graph context |
|
|
Find the most important nodes |
|
|
Find shortest path between two nodes |
|
|
Detect communities |
|
|
Understand the graph before querying |
|
|
Batch reference syntax
The batch_import tool lets edges reference nodes created in the same batch using @N notation, where N is the zero-based index into the nodes array:
batch_import(
nodes=[
{"labels": ["Person"], "properties": {"name": "Alice"}}, # @0
{"labels": ["Person"], "properties": {"name": "Bob"}}, # @1
],
edges=[
{"source_ref": "@0", "target_ref": "@1", "edge_type": "KNOWS"},
],
)You can also mix batch references with existing node IDs: {"source_ref": "@0", "target_ref": 42, ...}.
Cypher normalization
The execute_gql tool automatically normalizes common Cypher syntax to GQL so agents trained on Cypher work out of the box. Currently the following transformations are applied:
Cypher keyword | GQL equivalent |
|
|
Keywords that are shared between Cypher and GQL (such as MATCH, RETURN, WHERE, WITH, LIMIT, DETACH DELETE) pass through unchanged. Cypher-only keywords like MERGE or OPTIONAL MATCH are not supported and will produce a clear error message from the query engine.
Development
git clone https://github.com/GrafeoDB/grafeo-mcp
cd grafeo-mcp
uv sync
uv run pytest # Run tests
uv run ruff check . # Lint
uv run ruff format . # Format
uv run ty check # Type checkSee Also
grafeo-memory includes a built-in MCP server (
grafeo-memory-mcp) that wraps the high-level memory API — extract, reconcile, search, summarize. If you need AI memory management rather than raw graph access, useuv add grafeo-memory[mcp].
License
Apache-2.0
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/GrafeoDB/grafeo-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server