PartCAD — Claude Code MCP server: what it does, how to install
MCP server to inspect, render, test, and export physical parts and assemblies from PartCAD packages in your IDE.
claude mcp add --env PC_PATH=<PC_PATH> --transport stdio partcad -- uvx partcadWhat PartCAD does
PartCAD treats physical hardware designs as software code. A package lives in a Git repository centered on a partcad.yaml manifest. That file defines CAD scripts, parts, assemblies, materials, and physical constraints.
Connecting the MCP server exposes the pc tooling directly to coding agents. It handles scripts from CadQuery, build123d, OpenSCAD, and FreeCAD alongside standard STEP, STL, and 3MF files. Through tool calls, an assistant can render projections, inspect mating interfaces, run MuJoCo simulations, and generate bills of materials.
Running the server requires uvx. If your package is outside the current directory, set the PC_PATH environment variable to that folder. Model renders can be cached locally or in S3 so team members never recompute identical geometry.
What it helps with
- render CAD parts and assemblies into SVG, PNG, or DXF from chat
- export physical models into STEP, STL, 3MF, or glTF formats
- generate bills of materials and assembly instruction books in HTML or PDF
- run automated tests on physical interfaces, ports, and kinematics
Example prompts for the agent
- Render the part
mounting_bracketto SVG from ourpartcad.yamlpackage - Generate the bill of materials and assembly guide for
robot_armin HTML - Export the assembly
housingto STEP and STL files
How to install PartCAD
Platform CLI
claude mcp add --env PC_PATH=<PC_PATH> --transport stdio partcad -- uvx partcadReplace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from partcad <command>
Platform CLI
codex mcp add partcad --env PC_PATH=<PC_PATH> -- uvx partcadReplace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from partcad <command>
Config file
{
"mcpServers": {
"partcad": {
"command": "uvx",
"args": [
"partcad"
],
"env": {
"PC_PATH": "<PC_PATH>"
}
}
}
}Replace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from partcad <command>
Config file
{
"servers": {
"partcad": {
"type": "stdio",
"command": "uvx",
"args": [
"partcad"
],
"env": {
"PC_PATH": "<PC_PATH>"
}
}
}
}Replace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from partcad <command>
Platform CLI
gemini mcp add -e PC_PATH=<PC_PATH> partcad uvx partcadReplace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from partcad <command>
Step 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 PartCAD
How to install PartCAD in Claude Code?
Run claude mcp add partcad -- uvx partcad. If your workspace requires an explicit package directory path, run claude mcp add --env PC_PATH=<PC_PATH> --transport stdio partcad -- uvx partcad.
What does the PartCAD MCP server do?
It lets coding assistants inspect, render, test, and export CAD models defined in PartCAD packages. The agent reads partcad.yaml, processes geometry scripts, and outputs production files.
Which CAD tools and formats work with PartCAD?
PartCAD works with CadQuery, build123d, OpenSCAD, Chili3D, KiCad EDA, and FreeCAD files. Export targets include STEP, BREP, STL, 3MF, OBJ, glTF, and URDF models.