trace-mcp — Claude Code MCP server: features and setup
trace-mcp indexes a repository so an agent can retrieve code context instead of repeatedly reading files. Use it to explore a project or prepare for a pull request review.
claude mcp add trace-mcp -- npx -y trace-mcpWhat trace-mcp does
trace-mcp creates a code index that an agent can query for project details. It lists support for 81 languages and integrations with 88 frameworks. Project code stays local.
Install the server with npm install -g trace-mcp, then connect it to Claude Code with claude mcp add trace-mcp -- npx -y trace-mcp. Run trace add from the repository directory to index that project. Claude Code needs the MCP connection configured before it can use the server.
What it helps with
- retrieve code context without repeatedly reading project files
- gather repository details for a pull request review
- index the repository in the current directory
Example prompts for the agent
- Use
trace-mcpto find the code related to this change and explain how it fits the project. - Gather project context with
trace-mcpbefore reviewing this pull request. - Index the current repository with
trace add.
How to install trace-mcp
Platform CLI
claude mcp add trace-mcp -- npx -y trace-mcpPlatform CLI
codex mcp add trace-mcp -- npx -y trace-mcpConfig file
{
"mcpServers": {
"trace-mcp": {
"command": "npx",
"args": [
"-y",
"trace-mcp"
]
}
}
}Config file
{
"servers": {
"trace-mcp": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"trace-mcp"
]
}
}
}Platform CLI
gemini mcp add trace-mcp npx -y trace-mcpStep 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 trace-mcp
How do I install trace-mcp in Claude Code?
Run claude mcp add trace-mcp -- npx -y trace-mcp. Then open the repository directory and run trace add to index the project.
What does trace-mcp do?
It indexes a codebase and lets an agent retrieve project context rather than reading the same files repeatedly.
Which platforms support trace-mcp?
Listed platforms include Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, and Zed.