AsusWRT MCP Server
Provides tools for monitoring and managing AsusWRT and AsusWRT-Merlin routers via SSH, including network diagnostics, client management, wireless settings, and security features.
Allows enabling or disabling the OpenVPN server on the router.
Supports monitoring and managing WireGuard VPN settings on the router.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@AsusWRT MCP Server list connected clients"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
AsusWRT MCP Server
mcp-name: io.github.teefloo/asuswrt-mcp
Model Context Protocol (MCP) server for secure, controlled administration of AsusWRT and AsusWRT-Merlin routers via SSH.
Overview
This MCP server provides AI assistants (like Claude, Cursor, etc.) with a safe interface to monitor and manage AsusWRT routers. It operates exclusively over SSH using allowlisted operations—no arbitrary command execution, no firmware modifications, and no factory resets.
Related MCP server: OpenWRT SSH MCP Server
Features
Read-Only Monitoring (42 tools)
Category | Tools |
Identity & Health | Router model, firmware version, uptime, load, memory |
Network | LAN/WAN details, DNS config, IPv6 status, routing table |
Clients | Connected clients, DHCP leases, ARP neighbors |
Wireless | Radio status, SSIDs, guest networks, client counts per band |
Services | Running processes, open ports, cron jobs |
Storage | USB devices, mounts, partitions, filesystem usage |
Security | UPnP, DDNS, Samba status, conntrack usage |
VPN | OpenVPN server, WireGuard, VPN client profiles |
Administration | Web admin ports, SSH/telnet access settings |
Diagnostics | SSH TCP/banner/auth diagnostics, config snapshot |
Mutation Tools (with safety guards)
All mutation tools require:
confirm: trueparameterASUSWRT_ALLOW_MUTATIONS=trueenvironment variableSupport for
dry_run: trueto preview changes
Tool | Description |
| Restart allowlisted services (httpd, firewall, wireless, dnsmasq, etc.) |
| Enable/disable DHCP server |
| Enable/disable UPnP |
| Enable/disable Wi-Fi radio bands |
| Enable/disable guest Wi-Fi |
| Toggle LAN access for guest Wi-Fi |
| List, add, remove, enable/disable port forwarding rules |
| Enable/disable OpenVPN server |
| List, block, unblock, remove parental control rules |
| Toggle block-all mode |
| List, add, remove DHCP static reservations |
Safety Model
No arbitrary SSH: Only allowlisted commands are executed via NVRAM and service calls
No firmware operations: No flash, reset, or bootloader access
Secret redaction: Passwords and sensitive data are never exposed in tool responses
Dry-run support: Every mutation can be previewed before applying
Confirmation required: Mutations require explicit
confirm=TrueSSH-only transport: No exposure of the router's web API
Prerequisites
Python 3.11+
An AsusWRT or AsusWRT-Merlin router with SSH access enabled
Network connectivity from the MCP client to the router
Installation
1. Clone and setup
git clone https://github.com/Teeflo/asuswrt-mcp.git
cd asuswrt-mcp
# Create virtual environment
python -m venv .venv
# Activate (Linux/macOS)
source .venv/bin/activate
# Activate (Windows)
.venv\Scripts\activate
# Install dependencies
pip install -e .2. Configure environment
# Copy example configuration
cp .env.example .env
# Edit with your router credentials
# Use your favorite editor:
notepad .env # Windows
nano .env # Linux/macOS3. Configure .env
# Required: Router connection
ASUSWRT_HOST=192.168.1.1
ASUSWRT_SSH_USERNAME=admin
ASUSWRT_SSH_PASSWORD=your_password
# Optional: SSH key authentication
# ASUSWRT_SSH_KEY_FILE=~/.ssh/id_rsa
# Optional: Enable mutations (disabled by default)
# ASUSWRT_ALLOW_MUTATIONS=true
# Optional: Connection settings
# ASUSWRT_SSH_PORT=22
# ASUSWRT_TIMEOUT_SECONDS=10Usage
Run the MCP server
# Standard stdio mode
python -m asuswrt_mcp.server
# Or use the entry point
asuswrt-mcpConfigure in Claude Desktop / Cursor
Add to your claude_desktop_config.json:
{
"mcpServers": {
"asuswrt-mcp": {
"command": "C:\\path\\to\\asuswrt-mcp\\.venv\\Scripts\\python.exe",
"args": ["-m", "asuswrt_mcp.server"],
"env": {
"ASUSWRT_HOST": "192.168.1.1",
"ASUSWRT_SSH_USERNAME": "admin",
"ASUSWRT_SSH_PASSWORD": "your_password"
}
}
}
}Using with npx Inspector (development)
npx @modelcontextprotocol/inspector python -m asuswrt_mcp.serverDevelopment
Run tests
pip install -e ".[dev]"
pytestRun with live router integration tests
ASUSWRT_TEST_ROUTER=1 pytestProject Structure
asuswrt-mcp/
├── src/asuswrt_mcp/
│ ├── server.py # FastMCP entrypoint & tool definitions
│ ├── service.py # Business logic & router operations
│ ├── config.py # Settings management
│ ├── clients/
│ │ └── ssh.py # SSH client wrapper
│ ├── nvram.py # NVRAM parsing utilities
│ ├── ssh_parsers.py # Output parsers for SSH commands
│ ├── security.py # Mutation guards & redaction
│ ├── validators.py # Input validation
│ ├── responses.py # Tool response formatting
│ ├── errors.py # Custom exceptions
│ └── serialization.py # Safe serialization
├── tests/ # Test suite (69 tests)
├── .env.example # Example configuration
├── pyproject.toml # Project metadata
└── README.md # This fileLicense
MIT License - see LICENSE for details.
Acknowledgments
asusrouter for the underlying Python library
MCP for the protocol specification
AsusWRT-Merlin for the firmware
Available Tools
47 toolsasuswrt_admin_accessA
Inspect web, SSH, and telnet administrative access settings.
Inputs: no named parameters.
asuswrt_arp_neighborsA
List ARP/IP neighbor entries known by the router.
Inputs: no named parameters.
asuswrt_capabilitiesB
Return server capabilities, guardrails, and safe settings.
Inputs: no named parameters.
asuswrt_clientsB
List connected clients reported by the router.
Inputs: no named parameters.
asuswrt_config_snapshotA
Fetch a redacted read-only configuration snapshot.
Inputs: no named parameters.
asuswrt_conntrack_statusA
Inspect conntrack table usage and limits.
Inputs: no named parameters.
asuswrt_cron_jobsA
Inspect scheduled cron jobs reported by cru.
Inputs: no named parameters.
asuswrt_ddns_statusA
Inspect Dynamic DNS enablement and current provider settings.
Inputs: no named parameters.
asuswrt_dhcp_configA
Inspect DHCP server pool settings and static reservations.
Inputs: no named parameters.
asuswrt_dhcp_leasesB
List active DHCP leases from dnsmasq.
Inputs: no named parameters.
asuswrt_dhcp_reservationC
List, add, or remove DHCP static reservations via SSH NVRAM.
Inputs: action (required), mac, ip, name, +2 more.
asuswrt_dhcp_serverC
Enable or disable the DHCP server.
Inputs: enabled (required), confirm, dry_run.
asuswrt_dns_configA
Inspect WAN and LAN DNS settings reported by NVRAM.
Inputs: no named parameters.
asuswrt_guest_lan_accessC
Toggle LAN access for a guest Wi-Fi slot.
Inputs: band (required), slot (required), allow_lan (required), confirm, +1 more.
asuswrt_guest_networksB
List guest Wi-Fi networks and LAN-access state.
Inputs: no named parameters.
asuswrt_guest_wifiC
Enable or disable a guest Wi-Fi slot.
Inputs: band (required), slot (required), enabled (required), confirm, +1 more.
asuswrt_healthA
Fetch router identity and basic health data.
Inputs: no named parameters.
asuswrt_identityB
Fetch router model and firmware identity.
Inputs: no named parameters.
asuswrt_interface_statsA
Inspect per-interface RX/TX counters from /proc/net/dev.
Inputs: no named parameters.
asuswrt_ipv6_statusA
Inspect IPv6 service, prefix, and router address details.
Inputs: no named parameters.
asuswrt_kernel_modulesA
Inspect loaded kernel modules reported by lsmod.
Inputs: no named parameters.
asuswrt_lan_detailsA
Inspect LAN interface, addressing, and DHCP presence.
Inputs: no named parameters.
asuswrt_mountsA
Inspect mounted filesystems and mount options.
Inputs: no named parameters.
asuswrt_network_overviewA
Fetch LAN, WAN, and routing overview details.
Inputs: no named parameters.
asuswrt_open_portsA
Inspect listening TCP/UDP sockets reported by netstat.
Inputs: no named parameters.
asuswrt_parental_accessC
List or manage AsusWRT parental access rules.
Inputs: action (required), mac, name, confirm, +1 more.
asuswrt_parental_block_allC
Toggle parental-control block-all mode.
Inputs: enabled (required), confirm, dry_run.
asuswrt_partitionsA
Inspect block-device partitions reported by the router kernel.
Inputs: no named parameters.
asuswrt_policy_routingB
Inspect policy-routing rules reported by ip rule.
Inputs: no named parameters.
asuswrt_port_forwardingC
List, enable/disable, add, or remove port forwarding rules.
Inputs: action (required), name, ip, port, +5 more.
asuswrt_radioC
Enable or disable a main Wi-Fi radio band.
Inputs: band (required), enabled (required), confirm, dry_run.
asuswrt_restart_serviceC
Restart an allowlisted AsusWRT service.
Inputs: service (required), confirm, dry_run.
asuswrt_route_tableA
Inspect the router IPv4 route table.
Inputs: no named parameters.
asuswrt_samba_statusA
Inspect Samba/SMB status and related processes.
Inputs: no named parameters.
asuswrt_service_processesA
List key allowlisted router processes and services.
Inputs: no named parameters.
asuswrt_ssh_diagnosticsA
Diagnose SSH TCP reachability, banner exchange, and authentication.
Inputs: no named parameters.
asuswrt_storage_usageB
Inspect storage/filesystem usage reported by the router.
Inputs: no named parameters.
asuswrt_system_statsA
Fetch router uptime, load, and memory statistics.
Inputs: no named parameters.
asuswrt_time_syncA
Inspect timezone and NTP synchronization settings.
Inputs: no named parameters.
asuswrt_upnpC
Enable or disable UPnP.
Inputs: enabled (required), confirm, dry_run.
asuswrt_upnp_statusA
Inspect UPnP enablement and housekeeping settings.
Inputs: no named parameters.
asuswrt_usb_overviewA
Inspect USB/storage-related partitions, mounts, and filesystems.
Inputs: no named parameters.
asuswrt_vpn_overviewB
Inspect configured VPN modes and related processes.
Inputs: no named parameters.
asuswrt_vpn_serverC
Enable or disable the OpenVPN server toggle.
Inputs: enabled (required), confirm, dry_run.
asuswrt_wan_detailsA
Inspect WAN protocol, IP, gateway, DNS, and interface details.
Inputs: no named parameters.
asuswrt_web_adminB
Inspect web admin ports and related web processes.
Inputs: no named parameters.
asuswrt_wireless_overviewB
Inspect wireless radios, SSIDs, and connected band counts.
Inputs: no named parameters.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 47 tools
All 47 tools have distinct names and clearly separated purposes, from inspecting specific subsystems (ARP, DNS, DHCP) to controlling actions (enable/disable, toggle). Even closely related tools like guest_networks, guest_wifi, and guest_lan_access target different aspects of guest Wi-Fi management.
Every tool follows the consistent pattern 'asuswrt_<noun_or_noun_verb>' with snake_case. The prefix unifies the set, and the suffixes are descriptive and predictable (e.g., _status, _config, _details, _enable, _disable).
47 tools is excessive for a single MCP server. While the domain of router management is broad, many tools are highly granular (separate tools for DHCP config, leases, reservations, and server), leading to bloat. The server would benefit from consolidation or splitting into sub-servers.
The tool set covers an extensive range of router features: network configuration, wireless, guest networks, VPN, port forwarding, parental controls, system health, and more. Minor gaps exist (e.g., no firmware update or QoS control), but the surface is comprehensive for routine monitoring and administration.
Maintenance
Related MCP Connectors
- DNS-DATA RemoteDeprecatedcom.dns-data
Connect AI assistants to authorized Windows and macOS devices for files, commands, and management.
Connect AI assistants to your approved computer for files, commands, browser and desktop tasks.
Connect AI assistants to explicitly paired computers, servers, and VMs for permitted remote actions.
Remote MCP access to user-authorized Linux, Windows and Intel Mac devices for AI assistants.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables management of ASUS routers running Asuswrt-Merlin firmware via SSH/SCP. Supports system monitoring, device management, WiFi control, service restarts, NVRAM operations, file transfers, VPN management, and custom command execution.13MIT
- AlicenseAqualityDmaintenanceEnables AI agents to manage OpenWRT routers remotely via SSH, supporting system monitoring, network management, OpenThread Border Router configuration, and package management through natural language commands.1917MIT
- AlicenseAqualityDmaintenanceEnables AI assistants to securely execute remote SSH commands, perform file transfers, and monitor system status through a standardized interface. It features robust security controls including command whitelisting, blacklisting, and credential isolation to prevent unauthorized operations.1020 npmMIT
- AlicenseAqualityDmaintenanceEnables AI assistants to read-only monitor iStoreOS/OpenWRT routers via SSH or HTTP/ubus API, providing 31 tools for system status, network info, logs, and plugin status (OpenClash, Passwall, AdGuardHome, etc.).31MIT