codegraph-mcp
Allows ingesting any GitHub repository's code into a Neo4j knowledge graph and provides tools to query the graph for file dependencies, structure, function definitions, and more.
Click 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., "@codegraph-mcpshow me the structure of the src directory in facebook/react"
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.
codegraph-mcp
Knowledge-Graph MCP Server for GitHub repos. Ingests any GitHub repo's code into a Neo4j graph (Repository / File / Function nodes; CONTAINS / DEFINES / IMPORTS / CALLS edges) and exposes that graph as read-only MCP tools to any MCP host — Claude Desktop, opencode, Cursor, or any client that speaks the Model Context Protocol.
Status
v0.1 — stdio transport, Neo4j 5.x backend, Python ast + tree-sitter (JS/TS/TSX) parsing.
Related MCP server: revibe-mcp
Quick start
git clone <codegraph-mcp> && cd codegraph-mcp
uv sync --extra dev # all deps pinned via uv.lock
docker compose up -d # Neo4j on bolt://localhost:7687
cp .env.example .env
uv run pytest -m "not slow and not integration"Ingest a repo
uv run codegraph ingest https://github.com/<owner>/<name>
# → {"graph_id": "owner/name", "files": 142, "functions": 880, ...}Connect an MCP host
Claude Desktop (claude_desktop_config.json)
{
"mcpServers": {
"codegraph": {
"command": "uv",
"args": ["run", "--directory", "C:\\path\\to\\codegraph-mcp", "codegraph", "serve"]
}
}
}opencode (in opencode.json)
{
"mcp": {
"codegraph": {
"type": "local",
"command": ["uv", "run", "--directory", "/path/to/codegraph-mcp", "codegraph", "serve"]
}
}
}Cursor (~/.cursor/mcp.json)
{
"mcpServers": {
"codegraph": {
"command": "uv",
"args": ["run", "--directory", "/path/to/codegraph-mcp", "codegraph", "serve"]
}
}
}MCP Inspector (for testing without an MCP host)
uv run mcp dev src/codegraph/server.pyCLI
Command | Purpose |
| Clone + parse + load a repo into Neo4j |
| Run the MCP server (stdio) — spawned by the MCP host |
| Hard-wipe one repo from Neo4j (destructive) |
| List ingested repos |
Tools
Tool | Purpose |
| List ingested repos |
| Confirm a repo's graph exists; return file/function counts |
| Tiered tree view under a path |
| Flagship: what files/funcs depend on (or are depended on by) a file |
| Find functions/files by name |
| Deep detail on one node (line range, kind) |
Tech stack
Python 3.11+, mcp>=1.27,<2 (stable v1.x FastMCP), Neo4j 5.x, pydantic v2, tree-sitter, GitPython, pytest, ruff, mypy, uv.
See CONTRIBUTING.md for architecture, conventions, and testing strategy.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
No tool schema history has been recorded yet.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Hosted code graph over MCP: exact callers, dependencies, and cross-repo blast radius for AI agents.
251An MCP server that gives your AI access to the source code and docs of all public github repos
Code intelligence for LLMs. Analyze, search, and retrieve code from any public git repository.
The Cortex MCP server provides read-only access to real-time engineering context from the Cortex developer portal, allowing AI coding assistants to answer natural language questions about your organization's catalog (microservices, libraries, domains, teams, infrastructure), scorecards (engineering standards and best practices), initiatives (goals and deadlines), and Engineering Intelligence metrics. It includes tools for querying documentation, tracking personal entities, and accessing AI-assisted insights across the entire Cortex ecosystem.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceAI-native code intelligence graph that builds a persistent knowledge graph of your codebase in Neo4j and exposes it to AI assistants via MCP, enabling contextual code analysis, impact analysis, and dependency tracking.21-
- AlicenseAqualityDmaintenanceEnables analysis of any GitHub repository to get architecture, file roles, execution flows, system design Q\&A, and structured agent context. Works with MCP-compatible clients like Claude Desktop, Cursor, and Windsurf.647MIT
- AlicenseNot gradedqualityAmaintenanceProvides code intelligence for AI coding agents by indexing repositories into a hybrid knowledge graph, enabling agents to query dependencies, impact, and context through 28 MCP tools.3Apache 2.0
- AlicenseNot gradedqualityCmaintenanceEmbeds your codebase into a local vector and graph database and exposes it as an MCP tool, enabling AI assistants to perform fast semantic search over your code using Graph RAG.4MIT
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
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/Ritesh-977/codegraph-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server