codebase-memory-mcp MCP Server
Overview
Codebase memory mcp is an open-source server for the model context protocol designed to provide local code intelligence for artificial intelligence agents. Developed by deusdata, the project builds a persistent local knowledge graph connecting source code, documentation, configuration, and infrastructure. By maintaining this graph locally, it survives session restarts and context compaction, allowing coding agents and developers to understand repositories ranging from source files to the systems surrounding them.
The native c backend exposes seventeen model context protocol tools and parses various languages and file formats using vendored grammars, complemented by hybrid lsp type resolution for supported languages. An optional visual companion called cbm lens, currently in open beta version zero point zero point one, provides architecture maps, source reading, coverage diagnostics, and a galaxy graph. The installer supports numerous automatic or conditional client integrations, and indexing requires no hosted service or external api key.
What it can do
The server operates by parsing source files, documentation, and infrastructure configurations into a persistent local knowledge graph. The native c backend exposes seventeen model context protocol tools that let users search symbols, full-text, and local semantic data, as well as trace callers, dependencies, types, and routes. It processes code structures alongside markdown, restructredtext, asciidoc, pdf text pages, and architecture decision records, linking explanations directly to their corresponding code implementations.
Beyond source files, the knowledge graph extends to infrastructure and configuration files such as docker, kubernetes, helm, kustomize, terraform, openofu, terragrunt, ansible, shell scripts, make files, and ci configurations. The system uses vendored grammars and hybrid lsp type resolution to build these connections. Users can query the graph through supported coding agents via the model context protocol or interact with it natively using the command line interface and the cbm lens visual interface.
Install and configure
We did not find an install command in the project's README. Follow the instructions in the repository and review the code before you connect it to an AI client.
The official MCP Registry lists this server with these packages:
Environment variables:
| Variable | Required | Description |
|---|---|---|
VITE_EXPERIMENTAL_AGENTS |
see README | - |
CBM_CACHE_DIR |
see README | - |
XDG_CONFIG_HOME |
see README | - |
Requirements
The README mentions setup for these clients: Claude Code, Cursor, VS Code, Windsurf, Cline, Zed, Continue.
Use cases
Developers and coding agents can use the server to find unfamiliar features, follow call paths across different services, trace a deployment back to its source code, and assess which parts of a project a proposed change might affect. By combining structural, full-text, and semantic search with compact results, the tool helps reduce repeated file reads and token usage during agent interactions.
The server also connects implementation details with documentation and infrastructure. Users can index documentation sections and architecture decisions to find design explanations alongside symbols, or trace relationships through container orchestration and deployment configurations to understand how services run and deploy.
This server is intended for developers and teams using coding agents who want to provide persistent structural context, architectural understanding, and infrastructure mapping directly within their local development environments without relying on hosted cloud services.
Limitations and things to check
Source analysis and graph storage run locally on the user machine, and the native runtime requires no docker or language runtime. However, dynamic values and unresolved references can leave gaps in infrastructure tracing. The documentation does not specify all hardware prerequisites, but discussion issues note that large repositories can trigger out-of-memory crashes or high cpu usage during indexing operations.
The documentation does not say whether every client integration works identically across all operating systems, and certain installation paths or commands may encounter platform-specific issues or script execution policy restrictions on windows. Users should inspect installation scripts and review security release verifications before deployment.
Before you connect it:
- The README mentions: needs credentials or api keys; controls or scrapes a web browser.
- Read the code or the documentation of the tools it exposes, and note what each tool can do.
- Grant the smallest permissions you can: limit folders, API scopes and database roles.
- Keep credentials in environment variables or a secrets manager, never in a shared config file.
- Run it in a container or a separate user account if it can execute code or touch files.
Release history
The most recent releases published on GitHub:
- v0.12.1 (2026-10-16): # v0.12.1 Every install path works again, and Helm charts join the graph. v0.12.1 fixes v0.12.0's package installs and the other install paths we found broken while checking every channel. It also links Helm charts to what they deploy, and stops the graph from inventing a registry for container…
- v0.12.0 (2026-10-15): # v0.12.0 Meet CBM Lens, and a code graph that reads your documentation. v0.12.0 is the biggest release of codebase-memory-mcp yet: 231 merged pull requests since v0.11.0, 40 of them from the community. Four headlines define it. 1. CBM Lens Beta: the code graph, for humans. Until now the graph's…
- v0.11.0 (2026-09-15): # v0.11.0 A large release, and an unusually community-heavy one: 171 pull requests merged since v0.10.8 (9 of them dependency bumps), 76 of them from contributors outside the maintainer. Thank you — this release is mostly your work. It is a minor version rather than another 0.10.x patch because…
Known issues and troubleshooting
These are the most discussed threads on the project's issue tracker. They show what other users ran into; read them before you install, and check whether they are still open.
- 0.10.4 index_repository OOM-crashes on large repo — v0.9.0 indexed the same tree in ~13 min (open, 25 comments)
- "install" command does not work for opencode in windows 11 (closed, 25 comments)
- No such xattr: com.apple.quarantine (closed, 22 comments)
- Very high CPU usage (open, 20 comments)
- Claude never use codebase-memory-mcp except if I edit the CLAUDE.MD file (closed, 18 comments)
Maintenance and community
The repository has 210 contributors, 4,873 commits in the last 12 months, 577 open issues and pull requests. It is maintained by Martin Vogel, a GitHub user with 22 public repositories and 877 followers. GitHub's community checks found a security policy, contribution guidelines, a code of conduct.
Frequently asked questions
Is codebase-memory-mcp free to use?
The repository is released under the MIT license.
When was codebase-memory-mcp last updated?
The last commit was on 2026-10-31, and the project is marked active by our 12-month check.
Which AI clients does codebase-memory-mcp work with?
Its README gives setup notes for Claude Code, Cursor, VS Code, Windsurf, Cline, Zed, Continue. Other MCP-compatible clients may also work, but the project does not say so.
What is codebase memory mcp?
It is an open-source model context protocol server that creates a persistent local knowledge graph connecting your repository's code, documentation, configuration, and infrastructure for artificial intelligence coding agents and developers.
How many mcp tools does the server provide?
The native c backend exposes seventeen model context protocol tools for searching symbols, tracing relationships, and retrieving source evidence.
Does it require an internet connection or api key to index code?
No, source analysis and graph storage run entirely locally on your machine, requiring no hosted service or api key.
What is cbm lens?
Cbm lens is an optional visual companion currently in open beta version zero point zero point one that offers a source reader, architecture maps, coverage diagnostics, and a three-dimensional galaxy graph.
Sources
This page combines data from:
- codebase-memory-mcp on GitHub
- Codebase Memory — Local Code Intelligence & MCP
- Official MCP Registry entry (registry.modelcontextprotocol.io)
Security snapshot
- Needs credentials or API keys
- Controls or scrapes a web browser
Automated checks on public data, last run Oct 31, 2026. This is not a security audit. Read the code and decide which permissions to grant before you connect any MCP server.