pcb-mcp
Allows designing, inspecting, and exporting KiCad PCB boards, including placing footprints, connecting and routing traces, running DRC/ERC checks, and generating fabrication files (Gerbers, drill, POS, BOM, schematic PDF).
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
pcb-mcp
Grok-native KiCad MCP. Design, inspect, fix, and export KiCad 9/10 boards from a Grok session without clicking the GUI.
This is not a pcbnew API wrapper and not a clone of mixelpixx. Sixteen tools, in-process pcbnew, kicad-cli as the source of truth for DRC/ERC/export, every mutation ends in a PNG + DRC/ERC summary.
Register as pcb. Leave any existing [mcp_servers.kicad] (mixelpixx) alone.
Mandatory loop (keep it fast)
PNGs always land at:
<project>/.pcb-mcp/snapshots/current/pcb.png and sch.png (overwritten each snapshot).
pcb_open
pcb_snapshot / pcb_state # look
pcb_place symbol=Device:R footprint=Resistor_SMD:R_0805_2012Metric
pcb_connect R1.2 R2.1 net=NET1
pcb_place from_schematic=true # optional: push sch netlist onto the PCB
pcb_route net=NET1 dry_run=false
pcb_drc # full kicad-cli DRC (the slow-but-true check)
pcb_export_fab out_dir=fab
pcb_savePlace/connect/edit snapshot the board in ~0.3s and return a lite DRC (unconnected count from pcbnew). After routing, call pcb_drc for shorts/clearance. Prefer ref.pad (R1.2). Width/clearance come from the open netclass.
See SPEC.md for the tool contract.
Related MCP server: KiCAD MCP Server
Install
You need KiCad 9 or 10 (with pcbnew and kicad-cli) and the Grok CLI. Do not clone this into a KiCad project directory; keep it as its own repo.
KiCad's python.exe is isolated and ignores PYTHONPATH. Always launch this server with that interpreter via run.py. Never point Grok at a venv python.
1. Clone
git clone https://github.com/LukeVincent25/pcb-mcp.git
cd pcb-mcp2. Install Python packages into .deps
Use KiCad's python, not python from PATH:
Windows (this machine: E:\Kicad):
E:\Kicad\bin\python.exe scripts\install_deps.pyWindows (typical Program Files install):
& "C:\Program Files\KiCad\10.0\bin\python.exe" scripts\install_deps.pyLinux:
/usr/bin/python3 scripts/install_deps.py
# if that is not KiCad's interpreter:
"$HOME/kicad/bin/python" scripts/install_deps.pyThat runs pip install "mcp>=1.12,<2" "pytest>=8" --target .deps. .deps stays out of git.
Confirm pcbnew imports on that same interpreter:
E:\Kicad\bin\python.exe -c "import pcbnew; print(pcbnew.GetBuildVersion())"3. Register with Grok as server pcb
E:\Kicad\bin\python.exe scripts\register_grok.py --kicad-root E:\KicadThis writes [mcp_servers.pcb] in %USERPROFILE%\.grok\config.toml and does not change [mcp_servers.kicad].
Equivalent manual config:
[mcp_servers.pcb]
command = "E:\\Kicad\\bin\\python.exe"
args = ["E:\\pcb-mcp\\run.py"]
enabled = true
startup_timeout_sec = 60
tool_timeout_sec = 600
[mcp_servers.pcb.env]
PCB_MCP_KICAD_ROOT = "E:\\Kicad"
KICAD_ROOT = "E:\\Kicad"Adjust the two paths to your clone and KiCad install.
4. Verify
grok mcp doctor pcbYou want: handshake OK, 16 tools, healthy. Then: pcb_open → pcb_snapshot → design → pcb_drc → pcb_export_fab.
Tests (optional)
E:\Kicad\bin\python.exe scripts\run_tests.pyFixtures live under tests/boards/ (generated with pcbnew + kicad-cli, not hand-minified S-expressions).
What works (v1)
All 16 tools:
Tool | Does |
| Project session. Save refuses a clobber unless |
| Compact JSON, PNG paths, search, DRC delta. |
|
|
| Outline, copper layers, Default netclass rules, mounting holes. |
| Footprint and/or symbol by |
|
|
| 2-layer netclass-aware router. |
| Value, footprint, ref, side, netclass. |
| Gerbers, drill, POS, BOM, schematic PDF via |
Mutators take dry_run (default true) and on commit return snapshot + DRC. Track width and clearance come from the open board's netclass, not hardcoded vendor numbers.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Design, route, check, review and export manufacturable PCBs from plain language; KiCad import.
Design a KiCad PCB from a prompt: parts, schematic checks, routing, KiCad DRC and Gerbers.
Run ERC, DRC, parity, BOM and export checks on KiCad 9 boards before manufacturing.
Design and revise PCBs from plain language, track jobs, and retrieve design artifacts.
Related MCP Servers
- AlicenseCqualityDmaintenanceEnables LLMs to inspect, edit, analyze, and render PCB layouts in real-time using the KiCad IPC API, providing tools for board configuration, footprints, tracks, zones, nets, text, shapes, dimensions, exports, screenshots, and CLI automation.1001MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to interact with KiCAD for PCB design automation. Users can design PCBs using natural language, including component placement, routing, checks, and export.1MIT
- AlicenseBqualityCmaintenanceEnables AI assistants to interact with KiCAD for PCB design automation, including schematic editing, component placement, routing, DRC/ERC, and export.10038 npm2MIT
- AlicenseAqualityCmaintenanceEnables MCP clients such as Claude Code to work on KiCad 10 designs by driving kicad-cli for ERC, DRC, netlists and fabrication exports, KiCad's IPC API for live board editing, and lossless edits of schematic and project files. It also provides design review, routing, parts and datasheet tooling so a board can be treated as data and checked against fab limits.353MIT