MCP Hub
Back to servers

UniFi MCP Server

Enables managing UniFi networks through natural language, allowing users to monitor clients, check network health, and perform device actions like blocking or restarting access points. It securely connects UniFi Controllers to MCP clients with features like Google OAuth authentication.

Updated
Jan 30, 2026

UniFi MCP Server

A Model Context Protocol server for managing UniFi networks through Claude or other MCP clients.

Features

  • Network Monitoring - List clients, access points, and network health
  • Device Management - Block/unblock devices, restart APs, force reconnections
  • Search - Find devices by name, IP, or MAC address
  • Secure Access - Google OAuth authentication with email allowlisting
  • Remote Ready - Designed for access via Cloudflare Tunnel

Quick Start

# 1. Clone and setup
cp .env.example .env
# Edit .env with your credentials (see SETUP.md)

# 2. Start with Docker
docker-compose up -d

# 3. Open http://localhost:3000 and login with Google

See SETUP.md for detailed configuration instructions.

Available Tools

ToolDescription
list_clientsList all connected devices
get_clientGet details for a specific client
search_devicesSearch by name, IP, or MAC
list_access_pointsList all APs with status
get_network_healthNetwork health statistics
block_clientBlock a device from the network
unblock_clientUnblock a device
reconnect_clientForce a client to reconnect
restart_deviceRestart an AP or switch
list_blocked_clientsList blocked devices

Example Usage

Once connected to Claude:

"List all devices on my network"
"Find any devices with 'iPhone' in the name"
"Block the device with MAC aa:bb:cc:dd:ee:ff"
"Show me the status of all access points"
"Restart the living room AP"

Architecture

Claude Desktop → Cloudflare Tunnel → Docker Container → UniFi Controller
                     (HTTPS)         (Google OAuth)      (Local API)

Configuration

Required environment variables:

VariableDescription
SESSION_SECRETRandom secret for sessions
GOOGLE_CLIENT_IDGoogle OAuth client ID
GOOGLE_CLIENT_SECRETGoogle OAuth client secret
ALLOWED_EMAILSComma-separated allowed emails
UNIFI_HOSTUniFi controller IP address
UNIFI_USERNAMEUniFi admin username
UNIFI_PASSWORDUniFi admin password

Tech Stack

License

MIT

Reviews

No reviews yet

Sign in to write a review