
How to add Kubernetes MCP Server to Claude Desktop
Popular community server wrapping kubectl and Helm for cluster management via natural language. Paste the config into ~/Library/Application Support/Claude/claude_desktop_config.json and restart Claude Desktop.
Last updated June 15, 2026 ยท 1.4kโ ยท stdio ยท no auth
Claude Desktop config for Kubernetes MCP Server
npx -y mcp-server-kubernetes{
"mcpServers": {
"kubernetes-mcp-server": {
"command": "npx",
"args": [
"-y",
"mcp-server-kubernetes"
],
"env": {
"ALLOW_ONLY_NON_DESTRUCTIVE_TOOLS": "true"
}
}
}
}Setup steps
- 1Open Claude Desktop โ Settings โ Developer โ Edit Config (this opens ~/Library/Application Support/Claude/claude_desktop_config.json).
- 2Paste the Kubernetes MCP Server config below under the top-level "mcpServers" key.
- 3Fill in any placeholder secrets (API keys, paths) in the snippet.
- 4Save the file, then fully quit and reopen Claude Desktop.
- 5Open a chat and confirm Kubernetes MCP Server's tools appear under the ๐ tools menu.
Before you start
- Node.js (it runs via `npx mcp-server-kubernetes`)
- kubectl installed and on your PATH
- Helm v3 installed if you want to use the Helm tools (optional)
- A valid kubeconfig (default ~/.kube/config) with at least one configured context pointing at a reachable cluster (minikube, GKE, EKS, Rancher Desktop, etc.)
What Kubernetes MCP Server can do in Claude Desktop
kubectl_get / kubectl_describeList/retrieve resources and show detailed resource information.
kubectl_create / kubectl_apply / kubectl_deleteCreate resources, apply YAML manifests, and delete resources.
kubectl_logsFetch pod logs.
kubectl_patch / kubectl_scale / kubectl_rolloutUpdate specific fields, scale workloads, and manage deployment rollouts.
kubectl_contextList and switch kubectl contexts.
kubectl_genericRun an arbitrary kubectl command (disabled in non-destructive mode).
install_helm_chart / upgrade_helm_chart / uninstall_helm_chartManage Helm v3 releases.
port_forward / stop_port_forwardStart and stop port-forwarding to pods or services.
Security
It inherits your active kubeconfig context and can modify or delete cluster resources by default; set ALLOW_ONLY_NON_DESTRUCTIVE_TOOLS=true and point at a non-production context when experimenting. Note CVE-2026-46519: earlier versions only enforced the non-destructive flag at tool discovery, not execution โ upgrade to v3.6.0 or later, and always confirm which cluster the current context targets.
Kubernetes MCP Server + Claude Desktop FAQ
Where is the Claude Desktop config file?
Claude Desktop reads MCP servers from ~/Library/Application Support/Claude/claude_desktop_config.json. Paste the Kubernetes MCP Server config there under the "mcpServers" key and restart the client.
Is Kubernetes MCP Server safe to use with Claude Desktop?
It inherits your active kubeconfig context and can modify or delete cluster resources by default; set ALLOW_ONLY_NON_DESTRUCTIVE_TOOLS=true and point at a non-production context when experimenting. Note CVE-2026-46519: earlier versions only enforced the non-destructive flag at tool discovery, not execution โ upgrade to v3.6.0 or later, and always confirm which cluster the current context targets.
Does it need credentials of its own?
No. It uses your existing kubeconfig and current context, so the agent inherits whatever cluster permissions you already have. There is no separate API key.
How do I stop it from deleting things?
Set ALLOW_ONLY_NON_DESTRUCTIVE_TOOLS=true. This disables kubectl_delete, uninstall_helm_chart, cleanup_pods, node_management, and kubectl_generic while keeping read, create, and update tools.
Is Helm required?
Only if you want the Helm tools. Core kubectl operations work without Helm; install Helm v3 to enable install/upgrade/uninstall chart tools.