rsdoctor — Claude Code MCP server: Rspack build analysis
Feeds your agent Rspack build data: asset sizes, module dependencies, compilation timing and duplicate-package checks.
claude mcp add rsdoctor -- npx -y @rsdoctor/mcp-serverWhat rsdoctor does
Rsdoctor is a build analyzer for the Rspack ecosystem. The MCP server hands that data to an agent so it can work through build problems and suggest what to optimize.
What the server exposes: assets and their sizes, module dependencies, Loader and Plugin execution order, module resolution. Diagnostic checks come alongside — duplicate packages and ECMAScript syntax versions. All of it targets projects built with Rspack; you cannot point it at another bundler.
One npx command installs it, no config file needed. The server runs locally over stdio.
What it helps with
- find what made the bundle grow
- see which modules pull in extra dependencies
- check whether packages are duplicated in the tree
- measure how long compilation takes
- catch outdated ECMAScript syntax in the output
Example prompts for the agent
- Analyze the Rspack build and show me what weighs the most
- Find duplicate packages in the build
- Why did the build get slower — check the Rsdoctor data
How to install rsdoctor
Platform CLI
claude mcp add rsdoctor -- npx -y @rsdoctor/mcp-serverPlatform CLI
codex mcp add rsdoctor -- npx -y @rsdoctor/mcp-serverConfig file
{
"mcpServers": {
"rsdoctor": {
"command": "npx",
"args": [
"-y",
"@rsdoctor/mcp-server"
]
}
}
}Config file
{
"servers": {
"rsdoctor": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@rsdoctor/mcp-server"
]
}
}
}Platform CLI
gemini mcp add rsdoctor npx -y @rsdoctor/mcp-serverStep 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 rsdoctor
How do I install rsdoctor in Claude Code?
Run claude mcp add rsdoctor -- npx -y @rsdoctor/mcp-server. The server starts through npx and connects over stdio.
What does rsdoctor do?
It collects Rspack build data — assets, module dependencies, Loader and Plugin execution — and passes it to an agent for diagnosis and bottleneck hunting.
Which bundler does rsdoctor work with?
Rspack only. It is a build analyzer for the Rspack ecosystem and does not read other bundlers.