GPU MCP Server — MCP server for Claude Code, Codex, Cursor
Hands an agent live NVIDIA GPU telemetry: load, memory, temperature, power, PCIe and NVLink. Useful when you want to ask about the cards from the chat window.
claude mcp add gpu-mcp-server -- docker run -i --rm ghcr.io/pmady/gpu-mcp-server:v0.1.0What GPU MCP Server does
The server is written in Go on top of the official MCP SDK and NVIDIA go-nvml. It speaks stdio and runs as a local process next to your agent, calling NVML directly through cgo, so there is no metric pipeline to stand up first.
Four tools come with it. list_gpus enumerates devices with load and memory figures, get_gpu_metrics takes an index or UUID and returns the detailed set, get_gpu_processes maps usage to PIDs, and gpu_summary aggregates across every device. MIG instances show up as separate devices and inherit the parent card's shared readings, including temperature, power and PCIe.
Building from source needs Go 1.23+, CGO, NVML headers on Linux and NVIDIA drivers on the host. A prebuilt image on GHCR skips the toolchain: docker run --rm -i --gpus all ghcr.io/pmady/gpu-mcp-server:latest. The --gpus all flag only works with the NVIDIA Container Toolkit installed. Keep -i in place, or the stdio transport has nothing to talk over.
What it helps with
- check which GPU is busy without opening nvidia-smi
- trace memory on a card back to a PID
- read temperature and power draw per device
- average utilization and total memory across all cards
- tell MIG instances apart from their parent GPU
Example prompts for the agent
- List the GPUs on this machine with their utilization
- Show detailed metrics for GPU index 0
- Which processes are using the GPU right now?
How to install GPU MCP Server
Platform CLI
claude mcp add gpu-mcp-server -- docker run -i --rm ghcr.io/pmady/gpu-mcp-server:v0.1.0Platform CLI
codex mcp add gpu-mcp-server -- docker run -i --rm ghcr.io/pmady/gpu-mcp-server:v0.1.0Config file
{
"mcpServers": {
"gpu-mcp-server": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"ghcr.io/pmady/gpu-mcp-server:v0.1.0"
]
}
}
}Config file
{
"servers": {
"gpu-mcp-server": {
"type": "stdio",
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"ghcr.io/pmady/gpu-mcp-server:v0.1.0"
]
}
}
}Platform CLI
gemini mcp add gpu-mcp-server docker run -i --rm ghcr.io/pmady/gpu-mcp-server:v0.1.0Step 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 GPU MCP Server
How do I install GPU MCP Server in Claude Code?
Run claude mcp add gpu-mcp-server -- docker run -i --rm ghcr.io/pmady/gpu-mcp-server:v0.1.0. Docker has to be running on the machine already.
What does GPU MCP Server do?
It exposes NVIDIA GPU readings as MCP tools: utilization, memory, temperature, power, PCIe and NVLink throughput. Your agent calls them when a question touches the hardware.
What does the server need to run?
NVIDIA drivers on the target host, plus the NVIDIA Container Toolkit so the container can start with --gpus all. A source build also wants Go 1.23+, CGO and NVML headers on Linux.