Data as of

kubectl-mcp-server for VS Code: Setup & Config

kubectl-mcp-server connects VS Code to Kubernetes inspection and management workflows.

What you can do with kubectl-mcp-server in VS Code

A broad Kubernetes operations surface for assistant-led diagnostics, Helm work, and resource analysis.

  • Create, scale, or roll back deployments.
  • Inspect Helm releases and manage chart installations.
  • Review RBAC and secret-security findings.

Before you start: kubectl-mcp-server in VS Code

  • Node.js 14+ for the npx method
  • kubectl installed and configured
  • Access to a Kubernetes cluster

The README recommends this npx launch for MCP clients. Python installation instead requires Python 3.9+. Optional UI features have a separate dependency extra. Docker can use stdio or --transport sse. The tool list here is a selection of explicitly named README operations, not the entire catalog.

kubectl-mcp-server VS Code configuration

  1. Choose VS Code configuration scope

    For kubectl-mcp-server, open Workspace: .vscode/mcp.json. Merge into servers; preserve existing inputs.

  2. Add kubectl-mcp-server to VS Code

    Use the kubectl-mcp-server entry below in servers. Keep kubectl-mcp-server's documented stdio connection fields and your other VS Code entries.

  3. Check kubectl-mcp-server in VS Code

    kubectl-mcp-server: Start in VS Code’s MCP controls; inspect output and trust prompts.

Config file · Workspace: .vscode/mcp.json

JSON
{
  "servers": {
    "kubectl-mcp-server": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "kubectl-mcp-server"
      ],
      "env": {}
    }
  }
}

kubectl-mcp-server tools available to VS Code

kubectl-mcp-server's stored tool list documents 23 tools; compare it with VS Code's connected tool list, because the stored list is not a live check.

get_pods

Look for get_pods among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

get_logs

Look for get_logs among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

Retrieve logs from a pod.

get_pod_events

Look for get_pod_events among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

Inspect events associated with a pod.

diagnose_pod_crash

Look for diagnose_pod_crash among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

Investigate pod failures using diagnostic information.

create_deployment

Look for create_deployment among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

Create a Kubernetes deployment.

scale_deployment

Look for scale_deployment among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

Change the replica count of a deployment.

kubectl_rollout

Look for kubectl_rollout among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

Manage deployment rollout operations.

diagnose_network_connectivity

Look for diagnose_network_connectivity among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

check_dns_resolution

Look for check_dns_resolution among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

audit_rbac_permissions

Look for audit_rbac_permissions among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

check_secrets_security

Look for check_secrets_security among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

helm_list

Look for helm_list among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

install_helm_chart

Look for install_helm_chart among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

Install an application from a Helm chart.

helm_rollback

Look for helm_rollback among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

Return a Helm release to an earlier revision.

get_current_context

Look for get_current_context among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

Report the selected Kubernetes context.

switch_context

Look for switch_context among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

Select another configured Kubernetes context.

list_contexts

Look for list_contexts among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

List configured Kubernetes contexts.

get_resource_recommendations

Look for get_resource_recommendations among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

Suggest resource settings based on workload analysis.

get_idle_resources

Look for get_idle_resources among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

get_cost_analysis

Look for get_cost_analysis among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

get_overprovisioned_resources

Look for get_overprovisioned_resources among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

delete_resource

Look for delete_resource among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

show_cluster_overview_ui

Look for show_cluster_overview_ui among VS Code's agent-mode tools after starting kubectl-mcp-server through the MCP controls.

kubectl-mcp-server: full stored tool descriptions

Troubleshooting kubectl-mcp-server in VS Code

  • Make npx kubectl-mcp-server (Node.js/npm) available in the workspace, container, or remote environment hosting kubectl-mcp-server. Start through VS Code's MCP controls; inspect output and trust prompts.
  • kubectl-mcp-server uses stdio here: VS Code must keep the configured process running; protocol output belongs on stdout and diagnostics on stderr.
  • Known limitation: Needs kubectl configuration and working cluster access.
  • Known limitation: The tool catalog includes destructive resource operations.
  • Known limitation: Interactive dashboards require optional dependencies.
  • General VS Code troubleshooting lives in the /clients/vscode guide.

kubectl-mcp-server — details. VS Code guide

Frequently asked questions

For kubectl-mcp-server, edit workspace .vscode/mcp.json. VS Code requires servers rather than mcpServers; preserve the displayed type on each entry.

VS Code's kubectl-mcp-server example uses stdio.

kubectl-mcp-server's VS Code configuration invokes npx kubectl-mcp-server (Node.js/npm).

kubectl-mcp-server's stored list contains 23 tools, including get_pods, get_logs, get_pod_events. Compare those names with VS Code's connected tool list; the stored list is not a live check.

Yes. The README documents pip installation and a Python module launch; that path needs Python 3.9 or newer.

Yes. Release inspection, chart and repository tools, installation, upgrade, and rollback are documented.

No. The catalog includes deployment creation and resource deletion; the README separately advertises a non-destructive mode.