docdex — Claude Code MCP server: repo-wide search and memory
Local-first documentation indexer and search daemon for codebases. Gives AI assistants ranked results, code structure awareness, and persistent project memory without uploading code to cloud storage.
claude mcp add docdex -- npx -y docdexWhat docdex does
Docdex runs as a background daemon and indexes your repository once. It builds a dependency graph using AST analysis, ranks search results by intent, and stores project knowledge locally. When an assistant asks a question via MCP, the server returns relevant context instead of literal string matches.
Supports Python, JavaScript, TypeScript, Rust, Go, Java, C++, and more. Install once via npm; it auto-configures for Claude Desktop, Cursor, Codex, Windsurf, and other editors. Also tracks conversation history, agent preferences, and project notes entirely on disk.
Requires Node.js >= 18. On Windows, install Microsoft Visual C++ Redistributable 2015-2022 (x64) first, or the daemon will fail to start.
What it helps with
- Search large repositories by intent and get ranked results, not raw string matches
- Let assistants understand code dependencies without uploading your project to a vector store
- Keep architecture decisions and project facts in one searchable place
- Index past conversations to find relevant context from earlier sessions
Example prompts for the agent
- Walk me through how auth works in this codebase and show me potential gaps
- Find all callers of
addressGeneratorand tell me what would break if I renamed it - Show every place we call
fetchand explain why most lack error handling
How to install docdex
Platform CLI
claude mcp add docdex -- npx -y docdexPlatform CLI
codex mcp add docdex -- npx -y docdexConfig file
{
"mcpServers": {
"docdex": {
"command": "npx",
"args": [
"-y",
"docdex"
]
}
}
}Config file
{
"servers": {
"docdex": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"docdex"
]
}
}
}Platform CLI
gemini mcp add docdex npx -y docdexStep by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more
Questions about docdex
How do I install docdex for Claude Code?
Run claude mcp add docdex -- npx -y docdex in your terminal, then restart Claude Code. The first run downloads the correct binary for your OS automatically.
What does docdex do?
It indexes your repo, learns the dependency graph between functions, and gives your assistant fast, ranked search over documentation. Everything runs locally; your code never leaves your machine.
What dependencies do I need besides Node.js?
On Windows, you must install Microsoft Visual C++ Redistributable 2015-2022 (x64). Run winget install --id Microsoft.VCRedist.2015+.x64 or download from Microsoft. Without it, the daemon exits with error 0xC0000135.