Neo4j

Fork of Neo4j MCP server with environment variable support
  • typescript

2

GitHub Stars

typescript

Language

6 months ago

First Indexed

2 months ago

Catalog Refreshed

Documentation & install

Readme and setup notes from the catalogue, plus a client-ready config you can copy for your MCP host.

Installation

Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "rebots-online-mcp-neo4j": {
      "command": "node",
      "args": [
        "dist/servers/mcp-neo4j-memory/main.js"
      ],
      "env": {
        "NEO4J_URL": "bolt://localhost:7687",
        "NEO4J_USER": "neo4j",
        "NEO4J_PASSWORD": "neo4j"
      }
    }
  }
}

You run an MCP server that connects to a Neo4j graph to store and query your knowledge graph. This server implements the Model Context Protocol with environment-based configuration for Neo4j and memory-backed graph operations, making it easy to build and query a graph of entities, relations, and observations from your applications.

How to use

You connect your MCP client to the Neo4j MCP Server to perform graph operations. The server exposes a memory-backed knowledge graph stored in Neo4j, with capabilities to create entities and relations, add observations, read the graph, search nodes, and open specific nodes by name. Use your MCP client to send requests that create and modify the knowledge graph, then query it to retrieve structured context for downstream tasks.

How to install

Follow these concrete steps to install and run the server locally.

# Prerequisites
# Ensure Node.js is installed (Node 12+ is recommended)
node -v
npm -v

# Install dependencies
npm install

# Build the server (if a build step is provided)
npm run build

# Start the server with Neo4j connection details
# Replace with your Neo4j instance details if different
NEO4J_URL="bolt://localhost:7687" \
NEO4J_USER="neo4j" \
NEO4J_PASSWORD="neo4j" \
node dist/servers/mcp-neo4j-memory/main.js

Configuration and usage notes

Configure the Neo4j connection via environment variables to keep secrets out of code. The server reads the following variables to connect to Neo4j:

  • NEO4J_URL: Neo4j connection URL (default bolt://localhost:7687)
  • NEO4J_USER: Neo4j username (default neo4j)
  • NEO4J_PASSWORD: Neo4j password (default neo4j) When running locally, you can provide these variables inline with the start command as shown in the installation steps.

Server capabilities and usage patterns

The server provides a memory-backed knowledge graph with these core actions:

  • create_entities: Create multiple new entities in the knowledge graph
  • create_relations: Create relations between entities
  • add_observations: Add new observations to existing entities
  • delete_entities: Delete entities and their relations
  • delete_observations: Delete specific observations from entities
  • delete_relations: Delete specific relations
  • read_graph: Read the entire knowledge graph
  • search_nodes: Search for nodes based on a query
  • open_nodes: Open specific nodes by their names These actions enable you to build, query, and maintain a rich context graph for your applications.

Available tools and data model

The Neo4j MCP memory tool supports a comprehensive set of operations to manage entities, relations, and observations inside the knowledge graph. You can batch-create entities, establish relationships, append observations to existing entities, remove elements, and perform full graph reads and targeted searches.

Development

Development workflow (if you are contributing):

  • Install dependencies
  • Build
  • Start the server The typical local start command uses a Node runtime to launch the memory-backed MCP server that connects to Neo4j.

Security and best practices

Keep your Neo4j credentials secure by using environment variables and avoid hard-coding passwords. When deploying to environments, provide NEO4J_URL, NEO4J_USER, and NEO4J_PASSWORD through your deployment’s secret management system.

Notes

This server variant supports environment-variable configuration for Neo4j and can connect to remote Neo4j instances. It enhances error handling and logging to aid debugging and supports custom ports. It remains compatible with the Model Context Protocol.

Available tools

create_entities

Create multiple new entities in the knowledge graph

create_relations

Create relations between entities (in active voice)

add_observations

Add new observations to existing entities

delete_entities

Delete entities and their relations

delete_observations

Delete specific observations from entities

delete_relations

Delete specific relations

read_graph

Read the entire knowledge graph

search_nodes

Search for nodes based on a query

open_nodes

Open specific nodes by their names

Built by
VeilStrat
AI signals for GTM teams
© 2026 VeilStrat. All rights reserved.All systems operational