
Neo4j Cypher MCP Server
OfficialRun Cypher queries and explore graph schema on Neo4j from your AI assistant.
Add to your client
Copy the config for your MCP client and paste it into its config file.
uvx mcp-neo4j-cypher --transport stdioPaste into ~/Library/Application Support/Claude/claude_desktop_config.json
{
"mcpServers": {
"neo4j-cypher-mcp-server": {
"command": "uvx",
"args": [
"mcp-neo4j-cypher",
"--transport",
"stdio"
],
"env": {
"NEO4J_URI": "bolt://localhost:7687",
"NEO4J_DATABASE": "neo4j",
"NEO4J_PASSWORD": "<your-password>",
"NEO4J_USERNAME": "neo4j"
}
}
}
}Requires `uv` (the Python package runner). Install it from https://docs.astral.sh/uv/ if `uvx` is not found.
Step-by-step guides: Add to Claude Desktop · Add to Cursor · Add to Windsurf
Before you start
- Python with the uv/uvx package manager (run via `uvx mcp-neo4j-cypher`)
- A running Neo4j instance (Neo4j Aura or self-managed), reachable over Bolt
- Neo4j connection details: NEO4J_URI (default bolt://localhost:7687), NEO4J_USERNAME, NEO4J_PASSWORD, NEO4J_DATABASE (default neo4j)
- The APOC plugin installed and enabled — required for the schema-inspection tool
- An MCP-capable client such as Claude Desktop or Cursor
About Neo4j Cypher MCP Server
The Neo4j Cypher MCP server (mcp-neo4j-cypher) lets an AI assistant inspect a Neo4j graph's schema and run Cypher read/write queries against it. It is part of the neo4j-contrib/mcp-neo4j collection from Neo4j Labs (maintained by the Field GenAI team), which also includes servers for memory/knowledge graphs, Aura cloud management, and data modeling.
The Cypher server exposes three tools: get_neo4j_schema (lists node labels, their properties, and relationships — requires the APOC plugin), read_neo4j_cypher (executes read queries), and write_neo4j_cypher (executes write/update queries). Write access can be disabled entirely with --read-only or NEO4J_READ_ONLY=true, and there are timeout and result token-limit controls to protect the database and the model context.
It connects to any Neo4j instance — Aura or self-managed — via Bolt, configured through NEO4J_URI/USERNAME/PASSWORD/DATABASE. It runs over stdio by default and also supports SSE and HTTP transports. When you run multiple databases, a --namespace flag prefixes tool names (e.g. mydb-read_neo4j_cypher) so they don't collide. Note that as a Neo4j Labs project it carries no SLA or backwards-compatibility guarantees.
Tools & capabilities (3)
get_neo4j_schemaList all node labels with their properties (name and type) and relationships to other node types (requires APOC)
read_neo4j_cypherExecute a read-only Cypher query and return the results
write_neo4j_cypherExecute an updating Cypher query and return an operation summary (disabled in read-only mode)
When to use it
- Use it when you want an assistant to translate natural-language questions into Cypher and query your graph
- Use it when you need an agent to understand your graph's schema (labels, properties, relationships) before querying
- Use it when you want safe, read-only exploration of a Neo4j database from an LLM via the --read-only flag
- Use it when building knowledge-graph or GraphRAG workflows backed by Neo4j
- Use it when you need agents to create or update nodes/relationships through controlled write queries
- Use it when you connect to multiple Neo4j databases and need namespaced tools to keep them separate
Quick setup
- 1Ensure your Neo4j instance is running and the APOC plugin is enabled
- 2Add the server to your MCP client config: command `uvx`, args `mcp-neo4j-cypher --transport stdio`
- 3Set NEO4J_URI, NEO4J_USERNAME, NEO4J_PASSWORD, and NEO4J_DATABASE in the server's env block
- 4Optionally add --read-only (or NEO4J_READ_ONLY=true) and/or --namespace for safety and multi-DB setups
- 5Restart the MCP client so it picks up the server
- 6Verify by asking the assistant to fetch the graph schema, then run a simple read query
Security notes
The server can execute write Cypher, so use a least-privilege Neo4j user if the agent should not mutate the graph. Credentials are passed via env vars, so prefer a dedicated account over the admin user.
Neo4j Cypher MCP Server FAQ
How do I authenticate to Neo4j?
Provide standard Bolt credentials via environment variables: NEO4J_URI, NEO4J_USERNAME, and NEO4J_PASSWORD (plus NEO4J_DATABASE to target a specific database). This works for both Aura and self-managed instances.
Why do I get no schema / a schema error?
The `get_neo4j_schema` tool depends on the APOC plugin. Install and enable APOC on your Neo4j instance, then retry.
Can I prevent the model from writing to my graph?
Yes. Start the server with `--read-only` or set NEO4J_READ_ONLY=true to disable `write_neo4j_cypher` entirely, leaving only schema and read tools.
How do I install and run it?
Run it with uvx, e.g. `uvx mcp-neo4j-cypher --transport stdio`, and reference that command in your MCP client config. SSE and HTTP transports are also supported.
Is this an officially supported Neo4j product?
It is published by Neo4j Labs (the Field GenAI team), so it's vendor-maintained but explicitly offered without SLAs or backwards-compatibility guarantees.
Alternatives to Neo4j Cypher MCP Server
Compare all alternatives →Google's official MCP server with prebuilt BigQuery tools, querying datasets via Application Default Credentials.
Read/write Postgres access plus index tuning, EXPLAIN plans, and database health analysis for AI agents.
Official Supabase server: manage tables, run SQL, branches, configs and edge functions from your AI client.
Compare Neo4j Cypher MCP Server with: