Skip to content

MCP server

Kubernetes MCP server

An open-source MCP server that lets AI read Kubernetes cluster state and logs and, if allowed, change resources and Helm releases.

At a glance

Maintained by
containers org (Red Hat-led open source project)
Tools exposed
10 listed below
Reviewed
September 24, 2026

Why it matters

What it does and why it matters

Kubernetes runs containers across many servers, and understanding what is happening in a cluster takes experience. This MCP server lets an assistant list namespaces, pods and events, read logs, get resources and, when allowed, create, update or delete resources and install Helm charts.

For operations teams, it speeds up investigating incidents. An assistant can answer "why is this pod crashing" by reading events and logs in one go.

It is maintained by the containers organization, an open-source project led by Red Hat engineers, not by the Kubernetes project itself. It offers a read-only mode, which we use by default. Write access, including deleting pods and running commands inside them, belongs only in development clusters.

Paired with an error tracker and a code repository, it lets an assistant follow an incident from alert to cause in one conversation, which shortens the time an engineer spends collecting context.

Use cases

Best business use cases

Incident triage

Read events and logs to explain a failing pod.

Cluster overview

Summarize what runs in each namespace.

Config review

Read resource definitions and spot mistakes.

Helm installs

Install charts in development clusters.

Team learning

Explain cluster concepts with real examples.

Tools

Available tools

Tool names as published by the maintainer at review time. Versions change, so check the repository for the current list.

Read and write: Read and write: reads cluster state and logs, and can create, update, scale and delete resources and Helm releases; read-only mode available.

  • configuration_view

    Show the current kubeconfig as YAML.

  • namespaces_list

    List namespaces in the cluster.

  • events_list

    List cluster events for troubleshooting.

  • pods_list

    List pods in all namespaces.

  • pods_log

    Get a pod's logs.

  • pods_exec

    Run a command in a pod.

  • pods_delete

    Delete a pod.

  • resources_get

    Get any Kubernetes resource by apiVersion, kind and name.

  • resources_create_or_update

    Create or update a resource with Server-Side Apply.

  • helm_install

    Install a Helm chart.

Workflows

Example workflows

Explain a crashing pod

  1. 1

    Connect in read-only mode.

  2. 2

    Ask why a pod is crashing.

  3. 3

    The assistant reads events and logs.

  4. 4

    It explains the likely cause.

  5. 5

    An engineer applies the fix.

Namespace review

  1. 1

    Ask for a summary of a namespace.

  2. 2

    The assistant lists workloads and services.

  3. 3

    It flags pods with restarts.

  4. 4

    It notes missing resource limits.

  5. 5

    The team plans fixes.

Prompts

Example prompts

  • “Why is the payments pod in the prod namespace restarting? Read its events and logs.”

  • “List all deployments without resource limits.”

  • “Summarize what is running in the staging namespace.”

Setup

Installation and configuration

Examples for Claude Desktop and Claude Code. Replace the placeholder values with your own keys, and store secrets outside version control.

Claude Desktop: claude_desktop_config.json

{
    "mcpServers": {
        "kubernetes": {
            "command": "npx",
            "args": [
                "-y",
                "kubernetes-mcp-server@latest"
            ]
        }
    }
}

Claude Code: terminal

claude mcp add kubernetes -- npx -y kubernetes-mcp-server@latest
  • Local server: stdio; kubernetes-mcp-server; kubernetes-mcp-server.
  • Needs: Kubeconfig (default ~/.kube/config, or KUBECONFIG env).

Security

Security considerations

  • Read-only mode

    Use read-only mode for anything beyond development.

  • Limited kubeconfig

    Use a service account with minimal roles.

  • Exec access

    Running commands in pods is powerful. Disable it where possible.

  • Open-source project

    Review the code and pin the version.

Related servers

Servers that pair well with it

Docker

A community MCP server that lets AI list, run, stop and remove Docker containers and manage images, networks and volumes.

AWS

The AWS API MCP server from AWS Labs lets AI run AWS CLI commands, suggest commands and plan changes, with read-only and consent modes.

Google Cloud

Google's gcloud MCP servers let AI run gcloud commands, read logs, metrics, alerts and traces, and work with Cloud Storage.

Keep exploring

FAQ

Questions people ask us

Have a question that is not here? Ask us directly.

Start a project

Want this connected to your own systems? We build AI workflows with MCP.

Send a short brief. We reply with questions, a suggested plan and an estimate you can compare with other offers.

Your privacy choices

We use necessary storage to run this site. With your permission we also use Google Analytics to see which pages help people, and load maps from Google. You can change this at any time. Read the cookie policy.