# Rancher

> Rancher is an open-source MCP server for cloud and infrastructure. MCP server that lets AI clients call the Rancher Kubernetes management API. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** CLI, API, self-hosted
- **Repository:** https://github.com/asklokesh/rancher-mcp-server
- **MCP Registry name:** io.github.asklokesh/rancher-mcp-server
- **Categories:** [cloud and infrastructure](https://ai-powered.com/categories/cloud-and-infrastructure)
- **Listing updated:** 2026-11-18

## About

The README describes this as a Model Context Protocol server that connects Rancher, the Kubernetes management platform, to GenAI applications. It runs over stdio and is installed from PyPI as rancher-mcp-server, with the Rancher API URL and an API key supplied as environment variables.

The README claims broad Rancher API coverage, several authentication methods, rate limiting, retry handling and async operation. It does not list the individual tools the server exposes, so check the repository before relying on specific operations.

It suits platform and DevOps teams who already manage clusters in Rancher and want an AI assistant to query or act on them through a standard MCP client. The project is MIT licensed and the README includes a short Python quick start.

## Features

- **Rancher API integration:** Connects MCP clients to the Rancher API for managing Kubernetes resources.
- **Multiple authentication methods:** The README says the server supports more than one way to authenticate to Rancher.
- **Rate limiting:** Built-in rate limiting is listed as part of the enterprise-ready feature set.
- **Retry and error handling:** The README says failed requests are retried and errors are handled.
- **Async operation:** Asynchronous support is listed for better performance under load.
- **stdio transport:** Runs over stdio so local MCP clients can launch it directly.

## Good for

- Asking an AI assistant for the state of Rancher-managed Kubernetes clusters
- Letting DevOps teams query Rancher resources from an MCP-capable chat client
- Building GenAI workflows that read or change Kubernetes deployments through Rancher

## Install

### Claude Code (Terminal)

```sh
claude mcp add rancher-mcp-server --env RANCHER_API_KEY='<RANCHER_API_KEY>' -- uvx rancher-mcp-server
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "rancher-mcp-server": {
      "command": "uvx",
      "args": [
        "rancher-mcp-server"
      ],
      "env": {
        "RANCHER_API_KEY": "<RANCHER_API_KEY>"
      }
    }
  }
}
```

### Cursor (~/.cursor/mcp.json)

```json
{
  "mcpServers": {
    "rancher-mcp-server": {
      "command": "uvx",
      "args": [
        "rancher-mcp-server"
      ],
      "env": {
        "RANCHER_API_KEY": "<RANCHER_API_KEY>"
      }
    }
  }
}
```

### VS Code (.vscode/mcp.json)

```json
{
  "servers": {
    "rancher-mcp-server": {
      "type": "stdio",
      "command": "uvx",
      "args": [
        "rancher-mcp-server"
      ],
      "env": {
        "RANCHER_API_KEY": "<RANCHER_API_KEY>"
      }
    }
  }
}
```

### Windsurf (~/.codeium/windsurf/mcp_config.json)

```json
{
  "mcpServers": {
    "rancher-mcp-server": {
      "command": "uvx",
      "args": [
        "rancher-mcp-server"
      ],
      "env": {
        "RANCHER_API_KEY": "<RANCHER_API_KEY>"
      }
    }
  }
}
```

### Other clients (your client's MCP settings (most use this shape))

```json
{
  "mcpServers": {
    "rancher-mcp-server": {
      "command": "uvx",
      "args": [
        "rancher-mcp-server"
      ],
      "env": {
        "RANCHER_API_KEY": "<RANCHER_API_KEY>"
      }
    }
  }
}
```

## FAQ

### How do I install it?

The README gives pip install rancher-mcp-server, or an editable install from the cloned repository.

### What configuration does it need?

The registry entry lists RANCHER_API_KEY as a required secret and RANCHER_API_URL as an optional variable pointing at the Rancher API.

### What license is it under?

The README states the MIT License.

### Is Rancher free?

Yes. Rancher is open source, so you can use and self-host it for free.

### How do I add Rancher to Claude Code?

Run this command in your terminal: claude mcp add rancher-mcp-server --env RANCHER_API_KEY='<RANCHER_API_KEY>' -- uvx rancher-mcp-server

### What are the best alternatives to Rancher?

The closest alternatives to Rancher are mcp, MCP Server, Azure, Civo MCP by usefulapi and Environment Nature Mcp.

## Where this comes from

- Description: written from the project's README and its MCP Registry entry.
- Install steps: from the official MCP Registry entry.

## Alternatives

- [mcp](https://ai-powered.com/mcp/mcp-mwfu4c84): mcp is an open-source MCP server for cloud and infrastructure.
- [MCP Server](https://ai-powered.com/mcp/mcp-server-mwercift): MCP Server is a freemium MCP server for cloud and infrastructure.
- [Azure](https://ai-powered.com/mcp/azure): Azure is an open-source MCP server for cloud and infrastructure.
- [Civo MCP by usefulapi](https://ai-powered.com/mcp/civo-mcp-by-usefulapi): Civo MCP by usefulapi is a freemium MCP server for cloud and infrastructure.
- [Environment Nature Mcp](https://ai-powered.com/mcp/environment-nature-mcp): Environment Nature Mcp is a freemium MCP server for cloud and infrastructure.
- [arr-mcp](https://ai-powered.com/mcp/arr-mcp): arr-mcp is an open-source MCP server for events and entertainment.

---
Source: https://ai-powered.com/mcp/rancher
