# Tailscale RMCP

This server lets an agent inspect Tailscale devices, routes, DNS, API keys, ACL policy, and users. Use it to check a tailnet or authorize a device from an MCP client.

- MCP server · `type=mcp` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed, Gemini CLI · ★ 5
- Author: dinglebear-ai
- License: AGPL-3.0 · policy=link-only · description only; the file stays with the author
- Source: https://github.com/dinglebear-ai/rtailscale
- Updated: 2026-10-01
- HTML: https://affpapa.org/en/nevibecode/mcp/tailscale-rmcp

## What it does

Tailscale RMCP exposes an MCP tool named `tailscale` alongside the `rtailscale` CLI. An agent can list devices, inspect an individual device, read subnet routes and DNS settings, and retrieve ACL policy, API keys, and tailnet users. Device authorization is available too.

Deleting a device requires `TAILSCALE_ALLOW_DESTRUCTIVE=true` on the server and a separate confirmation from the caller. You need a Tailscale API key with permissions for the actions you intend to use, plus a configured `TAILSCALE_TAILNET`. This server does not replace the Tailscale admin console or provide general WireGuard control.

Claude Code can connect over stdio with `npx` or use the HTTP endpoint. For local HTTP use, the documented command binds the server to `127.0.0.1`. Keep the API key in `TAILSCALE_API_KEY`; MCP tool arguments are not a place to pass that credential.

## Requirements
- Needs: Node.js (commands run via npx)
- Remote server: `https://ts.dinglebear.ai/mcp`
- Environment variables: `TAILSCALE_API_KEY`, `TAILSCALE_RMCP_VERSION`, `TAILSCALE_RMCP_REPO`, `TAILSCALE_RMCP_RELEASE_BASE_URL`, `RUST_LOG` — keys and tokens: ask the human for the values, never commit them or put them in shared files.

## Install

### Claude Code (native platform)

1. **Platform CLI**
```bash
claude mcp add --env TAILSCALE_API_KEY=<TAILSCALE_API_KEY> --env TAILSCALE_RMCP_VERSION=<TAILSCALE_RMCP_VERSION> --env TAILSCALE_RMCP_REPO=<TAILSCALE_RMCP_REPO> --env TAILSCALE_RMCP_RELEASE_BASE_URL=<TAILSCALE_RMCP_RELEASE_BASE_URL> --env RUST_LOG=<RUST_LOG> --transport stdio tailscale-rmcp -- npx -y @dinglebear/rtailscale
```
Replace <…> with your own values

2. **Platform CLI: remote server**
```bash
claude mcp add --transport http tailscale-rmcp https://ts.dinglebear.ai/mcp
```

### Codex

1. **Platform CLI: remote server**
```bash
codex mcp add tailscale-rmcp --url https://ts.dinglebear.ai/mcp
```

2. **Platform CLI**
```bash
codex mcp add tailscale-rmcp --env TAILSCALE_API_KEY=<TAILSCALE_API_KEY> --env TAILSCALE_RMCP_VERSION=<TAILSCALE_RMCP_VERSION> --env TAILSCALE_RMCP_REPO=<TAILSCALE_RMCP_REPO> --env TAILSCALE_RMCP_RELEASE_BASE_URL=<TAILSCALE_RMCP_RELEASE_BASE_URL> --env RUST_LOG=<RUST_LOG> -- npx -y @dinglebear/rtailscale
```
Replace <…> with your own values

### Cursor

**Config file**
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "tailscale-rmcp": {
            "url": "https://ts.dinglebear.ai/mcp"
        }
    }
}
```
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "tailscale-rmcp": {
            "command": "npx",
            "args": [
                "-y",
                "@dinglebear/rtailscale"
            ],
            "env": {
                "TAILSCALE_API_KEY": "<TAILSCALE_API_KEY>",
                "TAILSCALE_RMCP_VERSION": "<TAILSCALE_RMCP_VERSION>",
                "TAILSCALE_RMCP_REPO": "<TAILSCALE_RMCP_REPO>",
                "TAILSCALE_RMCP_RELEASE_BASE_URL": "<TAILSCALE_RMCP_RELEASE_BASE_URL>",
                "RUST_LOG": "<RUST_LOG>"
            }
        }
    }
}
```
Replace <…> with your own values

### GitHub Copilot

**Config file**
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "tailscale-rmcp": {
            "type": "http",
            "url": "https://ts.dinglebear.ai/mcp"
        }
    }
}
```
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "tailscale-rmcp": {
            "type": "stdio",
            "command": "npx",
            "args": [
                "-y",
                "@dinglebear/rtailscale"
            ],
            "env": {
                "TAILSCALE_API_KEY": "<TAILSCALE_API_KEY>",
                "TAILSCALE_RMCP_VERSION": "<TAILSCALE_RMCP_VERSION>",
                "TAILSCALE_RMCP_REPO": "<TAILSCALE_RMCP_REPO>",
                "TAILSCALE_RMCP_RELEASE_BASE_URL": "<TAILSCALE_RMCP_RELEASE_BASE_URL>",
                "RUST_LOG": "<RUST_LOG>"
            }
        }
    }
}
```
Replace <…> with your own values

### Gemini CLI

1. **Platform CLI: remote server**
```bash
gemini mcp add -t http tailscale-rmcp https://ts.dinglebear.ai/mcp
```

2. **Platform CLI**
```bash
gemini mcp add -e TAILSCALE_API_KEY=<TAILSCALE_API_KEY> -e TAILSCALE_RMCP_VERSION=<TAILSCALE_RMCP_VERSION> -e TAILSCALE_RMCP_REPO=<TAILSCALE_RMCP_REPO> -e TAILSCALE_RMCP_RELEASE_BASE_URL=<TAILSCALE_RMCP_RELEASE_BASE_URL> -e RUST_LOG=<RUST_LOG> tailscale-rmcp npx -y @dinglebear/rtailscale
```
Replace <…> with your own values

## When to use it
- list devices in a tailnet
- inspect subnet routes and DNS settings
- read ACL policy and tailnet users
- authorize a device on the tailnet
- delete a device with explicit confirmation

## Example prompts
- List the devices in my tailnet and summarize their details.
- Check the subnet routes and DNS settings for my tailnet.
- Authorize this device on the tailnet; ask me to confirm before deleting any device.

## Similar
- [GitHub](https://affpapa.org/en/nevibecode/mcp/github.md) — MCP server · ★ 33989
- [Netdata](https://affpapa.org/en/nevibecode/mcp/netdata.md) — MCP server · ★ 81163
- [Oh My Posh Validator](https://affpapa.org/en/nevibecode/mcp/oh-my-posh-validator.md) — MCP server · ★ 23654
- [Keploy](https://affpapa.org/en/nevibecode/mcp/keploy.md) — MCP server · ★ 18779
- [Coder](https://affpapa.org/en/nevibecode/mcp/coder.md) — MCP server · ★ 17191
- [mcp](https://affpapa.org/en/nevibecode/mcp/kubeshark-mcp.md) — MCP server · ★ 12110

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
