
kubectl-mcp-server
MCP server giving AI assistants kubectl and Helm control over Kubernetes clusters
The repository was last updated 40 days ago and is published under MIT.
kubectl-mcp-server is an open-source MCP server for cloud and infrastructure. It is available on CLI, API, Self-hosted, Linux, macOS and Windows.
- Pricing
- Open source
- Platforms
- CLI, API, Self-hosted
- What it can do
- Can delete data (2 tools)
- GitHub stars
- 974
- Last commit
Similar MCP servers
About kubectl-mcp-server
Lets an AI assistant inspect and change Kubernetes workloads through natural language instead of raw kubectl commands. Requests such as checking pod health, listing deployments, reading events or scaling a deployment are translated into kubectl and Helm operations against the clusters in your kubeconfig.
The default install registers 26 tools covering generic resource reads and writes, port forwarding, context switching and the full Helm release lifecycle. Additional toolsets for GitOps, cert-manager, policy engines, backups, service meshes and virtual clusters can be enabled with a flag. Read-only and confirm-before-destructive safety modes are available, and Secret values are redacted from tool output.
It suits platform and DevOps engineers who already work with Kubernetes and want an assistant that can run routine cluster queries and changes from their editor or chat client. Deployment is available over stdio for desktop clients or as a stateless HTTP server behind OAuth.
Tools this server provides (26)
Taken from the project documentation; the running server may differ.
From the tool list in its README, going by the names, 2 of 26 tools delete data and 1 changes data; 5 names don't say.
From the server's own tool labels and tool names; not verified by us.
- check_pod_healthName suggests: reads
- Check the health status of a pod.
- create_deploymentName suggests: changes
- Create a new deployment.
- delete_resourceName suggests: deletes
- Delete a Kubernetes resource.
- get_api_resourcesName suggests: reads
- List Kubernetes API resources.
- get_cluster_rolesName suggests: reads
- Get all cluster-wide RBAC roles.
- get_configmapsName suggests: reads
- Get all ConfigMaps in the specified namespace.
- get_current_contextName suggests: reads
- Get current kubeconfig context.
- get_deploymentsName suggests: reads
- Get all deployments in the specified namespace.
- get_eventsName suggests: reads
- Get all events in the specified namespace.
- get_logsName suggests: reads
- Get logs from a pod.
- get_namespacesName suggests: reads
- Get all Kubernetes namespaces.
- get_nodesName suggests: reads
- Get all nodes in the cluster.
- get_pod_eventsName suggests: reads
- Get events for a specific pod.
- get_podsName suggests: reads
- Get all pods in the specified namespace.
- get_rbac_rolesName suggests: reads
- Get all RBAC roles in the specified namespace.
- get_resource_usageName suggests: reads
- Get resource usage statistics via kubectl top.
- get_secretsName suggests: reads
- Get all Secrets in the specified namespace.
- get_servicesName suggests: reads
- Get all services in the specified namespace.
- health_checkName suggests: reads
- Check cluster health by pinging the API server.
- install_helm_chart
- Install a Helm chart.
- kubectl_explainName suggests: reads
- Explain a Kubernetes resource using kubectl explain.
- port_forward
- Forward local port to pod port.
- scale_deployment
- Scale a deployment.
- switch_context
- Switch current kubeconfig context.
- uninstall_helm_chartName suggests: deletes
- Uninstall a Helm release.
- upgrade_helm_chart
- Upgrade a Helm release.
What it does
- Generic kubectl operations
- Get, describe, logs, apply, patch and scale work across any resource kind, including custom resources.
- Helm release management
- Install, upgrade, uninstall and inspect Helm v3 releases from the assistant.
- Read-only and confirmation modes
- Safety flags hide write tools entirely or require approval before destructive calls.
- Secret redaction
- Secret data, bearer tokens and JWTs are replaced with placeholders in tool results.
- Opt-in ecosystem toolsets
- Enable extra toolsets for GitOps, certificates, policies, backups, service meshes and virtual clusters.
- Multi-cluster targeting
- Most tools accept a context parameter to query or change a specific cluster without switching.
Good for
- Find out why a pod is crashing using its logs and recent events
- Scale or roll back a deployment from a chat with the assistant
- Audit RBAC roles and ConfigMaps across namespaces
- Install or upgrade a Helm chart in a named cluster
- Compare resources between a production and a staging namespace
Pricing
Open source
Free and open source under the MIT License.
Prices change. Check hub.docker.com before you buy.
More servers for the same service
kubectl-mcp-server FAQ
Which tools are enabled by default?
The core and helm toolsets, which provide 26 tools. Other toolsets must be enabled explicitly.
Can kubectl-mcp-server run without write access to the cluster?
Yes. A read-only safety mode hides and blocks every tool that changes state.
How is the server installed?
It can be run with npx, installed from PyPI with pip or uvx, or started as a Docker container.
Does kubectl-mcp-server protect Secret values?
Secret data, stringData, bearer tokens and JWTs are redacted in every tool result by default.
Is kubectl-mcp-server free?
Yes. kubectl-mcp-server is open source, so you can use and self-host it for free.
What are the best alternatives to kubectl-mcp-server?
The closest alternatives to kubectl-mcp-server are k8s-mcp-server, mcp-k8s, Helm MCP, K8s MCP Server (Go) and MCP Kubernetes.
Where this comes from
- Description: written from the project's README and the project's website.

