Skip to main content
MCP server CX Codex

kubeview — Claude Code MCP server: what it does, how to install

Runs Kubernetes diagnostics through an isolated TypeScript runtime. Keeps intermediate logs and cluster events out of the model prompt.

Install into Claude Code · Platform CLI All methods and platforms ↓
claude mcp add --env KUBECONFIG=<KUBECONFIG> --env MCP_TRANSPORT=<MCP_TRANSPORT> --env MCP_MODE=<MCP_MODE> --env MCP_CODE_MODE_DISABLED_TOOLS=<MCP_CODE_MODE_DISABLED_TOOLS> --env MCP_ARGO_TOOLS=<MCP_ARGO_TOOLS> --transport stdio kubeview -- npx -y kubeview-mcp
Open on GitHub

What kubeview does

Kubeview provides code execution mode instead of dozens of standalone tools. The assistant evaluates TypeScript via run_code, querying the cluster API and Helm releases directly. Raw payloads never touch the context window. Intermediate logs stay inside the sandbox runtime.

Only two tools are exposed: run_code and kube_pod_exec. Shell execution in pods requires explicit elicitation and expires after 10 minutes. Network port forwarding stays blocked by default. Without Node.js 22 or higher and valid cluster access in KUBECONFIG, the server will not start.

What it helps with

  • inspect failing pods across namespaces without context bloat
  • correlate cluster events with Helm releases and Argo state
  • run diagnostic commands in containers behind approval gates
  • fetch and filter container logs in a single batch

Example prompts for the agent

  • Check pods with errors in the payments namespace and summarize their logs
  • Inspect cluster events and compare them against recent Helm revisions
  • Execute run_code to find pods restarting frequently and inspect their exit codes

How to install kubeview

Platform CLI

claude mcp add --env KUBECONFIG=<KUBECONFIG> --env MCP_TRANSPORT=<MCP_TRANSPORT> --env MCP_MODE=<MCP_MODE> --env MCP_CODE_MODE_DISABLED_TOOLS=<MCP_CODE_MODE_DISABLED_TOOLS> --env MCP_ARGO_TOOLS=<MCP_ARGO_TOOLS> --transport stdio kubeview -- npx -y kubeview-mcp

Replace <…> with your own values. 19 more environment variables are in the server README

Step 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 kubeview

How to install kubeview in Claude Code?

Run claude mcp add kubeview -e MCP_APPROVAL_STATE_SECRET=<MCP_APPROVAL_STATE_SECRET> -- npx -y kubeview-mcp in your terminal.

What does kubeview do?

It gives the model a sandboxed TypeScript environment to inspect Kubernetes clusters. Diagnostic scripts execute in a single call, preventing huge API payloads from consuming the context window.

What prerequisites are required for kubeview?

The server requires Node.js 22 or later. It also needs cluster credentials set through KUBECONFIG or an in-cluster service account.

Similar MCP servers

All MCP servers for DevOps and infrastructure →

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor