NestDaddy

Pi-hole MCP Server

io.github.ranklancer/pihole-mcp · v0.2.0

MCP server for Pi-hole v6 API — manage multiple instances: queries, lists, groups, stats

Connect Runs on your machine

Terminal
claude mcp add pihole-mcp -e PIHOLE_INSTANCES=<PIHOLE_INSTANCES> -e PIHOLE_BASE_URL=<PIHOLE_BASE_URL> -e PIHOLE_PASSWORD=<PIHOLE_PASSWORD> -- npx -y @ranklancer/[email protected]
claude_desktop_config.json
{
  "mcpServers": {
    "pihole-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@ranklancer/[email protected]"
      ],
      "env": {
        "PIHOLE_INSTANCES": "<PIHOLE_INSTANCES>",
        "PIHOLE_BASE_URL": "<PIHOLE_BASE_URL>",
        "PIHOLE_PASSWORD": "<PIHOLE_PASSWORD>"
      }
    }
  }
}
~/.cursor/mcp.json
{
  "mcpServers": {
    "pihole-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@ranklancer/[email protected]"
      ],
      "env": {
        "PIHOLE_INSTANCES": "<PIHOLE_INSTANCES>",
        "PIHOLE_BASE_URL": "<PIHOLE_BASE_URL>",
        "PIHOLE_PASSWORD": "<PIHOLE_PASSWORD>"
      }
    }
  }
}
.vscode/mcp.json
{
  "servers": {
    "pihole-mcp": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@ranklancer/[email protected]"
      ],
      "env": {
        "PIHOLE_INSTANCES": "<PIHOLE_INSTANCES>",
        "PIHOLE_BASE_URL": "<PIHOLE_BASE_URL>",
        "PIHOLE_PASSWORD": "<PIHOLE_PASSWORD>"
      }
    }
  }
}

Replace the values in angle brackets with your own. Keys stay on your machine; we never see them.

Tools

This server runs locally, so its tools are listed by your MCP client once it starts.

Environment variables

NameDescription
PIHOLE_INSTANCES
Required
Comma-separated list of Pi-hole instance names (e.g. 'pihole' or 'primary,secondary')
PIHOLE_BASE_URL
Required
Base URL of your first Pi-hole instance (e.g. 'http://192.168.1.100')
PIHOLE_PASSWORD
Required, secret
API password for your first Pi-hole instance

Details

Package@ranklancer/[email protected] (NPM, stdio)
First published12 Apr 2026
Last updated12 Apr 2026
Registry nameio.github.ranklancer/pihole-mcp

More other servers See all

Listing data from the official MCP registry. Status and tools from NestDaddy's daily check. Browse all MCP servers.