codescene-mcp-server — Claude Code MCP server: Code Health analysis
Feeds your AI assistant Code Health metrics from the local codebase: complexity, nesting, technical debt. Useful when AI writes code and maintainability matters.
claude mcp add codescene-mcp-server -- npx -y @codescene/codehealth-mcpWhat codescene-mcp-server does
The server runs on your machine and plugs into an assistant as a data source about code quality. The assistant asks for an analysis, the server answers with maintainability problems, complexity figures and technical debt, and those details get folded into the prompts.
Inside are Code Health tools gated by your license, plus public agent skills under skills/ for teams that want the same workflows in their own agentic pipelines. Agent guidance files ship with it too: AGENTS-full.md for CodeScene Core, AGENTS-standalone.md for standalone licenses, .amazonq/rules for Amazon Q.
Authentication comes first — the server will not work without it. The npx route needs Node.js 18 or later. Docker is on its way out: images between October 1 and December 31, 2026 cover bug fixes only, and nothing ships after December 31, 2026.
What it helps with
- catch technical debt that AI adds along with new code
- measure complexity and nesting before a refactor
- locate hotspots across the codebase
- get unhealthy code ready for AI refactoring
- wire code quality metrics into an agentic pipeline
Example prompts for the agent
- Analyze Code Health for
src/parser.tsand list the problem areas - Find the hotspots in this repository, sorted by complexity
- Check this patch for technical debt before I commit
How to install codescene-mcp-server
Platform CLI
claude mcp add codescene-mcp-server -- npx -y @codescene/codehealth-mcpPlatform CLI
codex mcp add codescene-mcp-server -- npx -y @codescene/codehealth-mcpConfig file
{
"mcpServers": {
"codescene-mcp-server": {
"command": "npx",
"args": [
"-y",
"@codescene/codehealth-mcp"
]
}
}
}Config file
{
"servers": {
"codescene-mcp-server": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@codescene/codehealth-mcp"
]
}
}
}Platform CLI
gemini mcp add codescene-mcp-server npx -y @codescene/codehealth-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 codescene-mcp-server
How do I install codescene-mcp-server in Claude Code?
Run claude mcp add codescene-mcp-server -- npx -y @codescene/codehealth-mcp. The server starts through npx, so Node.js 18 or later is required.
What does codescene-mcp-server do?
It hands the assistant Code Health results from your codebase: complexity, nesting, maintainability issues and technical debt.
What does the server need to run?
Configured authentication and Node.js 18 or later. Available tools depend on your license type, so copy the matching agent guidance file.