MikroTik MCP is the bridge between your AI assistant and your RouterOS fleet — let Claude, ChatGPT, or any MCP-capable client manage VLANs, IPv4 and IPv6 firewall rules, DHCP, NAT, WireGuard, and 17 other categories from a single prompt — on one router or across a whole fleet. No web UI clicks. No Winbox tabs.
MikroTik MCP is a Model Context Protocol server. It exposes your RouterOS device's configuration surface as typed tools — your AI client picks the right one, fills in the parameters, and runs it over SSH. You stay in the loop; the model just handles the syntax.
Every RouterOS noun has a verb. "Make a VLAN" maps onto mikrotik_create_vlan_interface with strict, validated arguments. No hallucinated CLI.
Run it over stdio for desktop AI clients, expose it as SSE for streaming agents, or wrap it in HTTP for REST consumers via mcpo.
Wrap risky operations in RouterOS safe-mode sessions. If a change locks you out, the device rolls everything back automatically — no manual recovery.
Each category exposes typed tools — create, list, get, update, remove, plus category-specific verbs like move_filter_rule or flush_dns_cache. Click any to jump to its reference.
Create, list, get, update, and remove tagged interfaces on any parent port. IDs 1–4094.
9 toolsFilter rules across input, forward, output chains. Move, enable, disable, plus a basic-setup helper.
8 toolsFilter rules under /ipv6 firewall — icmpv6, hop-limit, extension headers, address types.
ARP and IPv6 Neighbor Discovery tables — see what's on the segment and which port it's on.
7 toolsNamed IPv4 + IPv6 address sets for firewall rules — one tool set, a family argument.
srcnat / dstnat / masquerade. Port forwards, redirects, move, enable, disable.
10 toolsServers, networks, pools, plus live lease and DHCPv6 binding views.
15 toolsStatic records, regexp blocklists, cache + statistics, query testing.
14 toolsStatic, default, blackhole. Active filters, table + cache inspection, path checks.
15 toolsInterfaces, peers, key management, client-config generation, allowed-IPs.
18 toolsLocal accounts, groups, policies, active sessions, SSH keys, exports.
10 toolsBinary backups, .rsc configuration exports, section dumps, file transfer, restore.
10 toolsStream, filter by topic or severity, search, statistics, export, live monitor.
7 toolsNamed pools, range expansion, used-address inspection.
4 toolsStatus, enable, commit, rollback sessions. Auto-revert on connection loss.
19 toolsSimple queues, queue trees, queue types. Rate limit per VLAN, per client.
4 toolsBind, list, get, remove. Comments, network filters, dynamic detection.
4 toolsIPv6 bindings under /ipv6 — advertise, EUI-64, prefix delegation, global vs link-local.
Interfaces, security profiles, access lists, network scan, registration table.
4 toolsList, get, enable, disable any interface — physical or virtual.
fleetOne server, many routers — a YAML fleet inventory with per-device targeting via device.
Power-over-Ethernet monitoring — live PoE-out voltage, current, power, and per-port settings.
/ip vlan add in three hops.The MCP server advertises typed tools to your AI client. The client picks the right one based on context, fills the parameters, and posts back. The server validates, translates to RouterOS CLI, and runs it over SSH against your device.
Pick a transport, paste a config, point it at your router. The Docker route is the shortest — no Python toolchain required.
# Clone & build $ git clone https://github.com/wiresage/mikrotik-mcp.git $ cd mikrotik-mcp $ docker build -t mikrotik-mcp . # Run with stdio (IDE integration) $ docker run --rm -i \ -e MIKROTIK_HOST=192.168.88.1 \ -e MIKROTIK_USERNAME=sshuser \ -e MIKROTIK_PASSWORD=your_password \ -e MIKROTIK_PORT=22 \ mikrotik-mcp
$ git clone https://github.com/wiresage/mikrotik-mcp.git $ cd mikrotik-mcp # Create & activate venv $ python -m venv .venv $ source .venv/bin/activate # Install + run $ pip install -e . $ mcp-server-mikrotik
{
"mcpServers": {
"mikrotik": {
"command": "uvx",
"args": [
"mcp-server-mikrotik",
"--host", "<HOST>",
"--username", "<USERNAME>",
"--password", "<PASSWORD>",
"--port", "22"
]
}
}
}
$ docker run --rm -p 8000:8000 \ -e MIKROTIK_HOST=192.168.88.1 \ -e MIKROTIK_USERNAME=sshuser \ -e MIKROTIK_PASSWORD=your_password \ -e MIKROTIK_MCP__TRANSPORT=sse \ mikrotik-mcp # Server is up: # SSE: http://localhost:8000/sse # Streamable HTTP: http://localhost:8000/mcp # Health probe: GET /health
routeros-lsp is a Language Server Protocol server for RouterOS scripts (.rsc). Your editor — or your AI coding agent — gets immediate feedback while the script is being written: syntax errors, unknown menus, commands and parameters, and the variable-scope mistakes RouterOS only reveals at import time. A sibling of MikroTik MCP; it works on its own.
$vlanId is a local variable of an earlier line or of a block that has ended, so it is empty here (an imported file gives every line its own scope). Use ':global vlanId' or put the commands in one { } block. (RouterOS behaviour that the documentation does not describe)
'adress' is not a menu or command in /ip of the RouterOS 7.21.4 command database. Did you mean 'address'? (RouterOS behaviour that the documentation does not describe)
This command takes no unnamed arguments, and a '#' only starts a comment at the beginning of a command, so RouterOS reads this as an argument. Put ';' before the comment. (RouterOS behaviour that the documentation does not describe)
':set vlanId' needs 'vlanId' to be declared first, with ':local vlanId' or ':global vlanId' earlier in the same block or in a block around it. 'vlanId' is declared elsewhere in this file, but each line of an imported file is its own scope and a block that has ended hides its names. Declare it again here or put the commands in one { } block. (RouterOS behaviour that the documentation does not describe)
disabled parameter of /ip address add
Defines whether item is ignored or used
Values: no, yes
Built to stay quiet when you're right. Checked against RouterOS 7.21.4 on 16,900 generated command lines, it never reported one the router accepts. It does miss some the router rejects — mostly the kinds it doesn't check, like parameter values. Method and limits →
Syntax, variables, menus and commands: 36 rules, each with an id, a severity and a label for how well founded it is. Messages say what RouterOS will do and how to fix it.
Menus, commands and parameters (required first), values after name=, variables in scope. Hover shows the description, type and values from the command database.
Functions, :global and :local declarations and the menu headers of an export fill the outline; blocks, continued lines and comment runs fold.
routeros-lsp check runs the same analysis for CI, a pre-commit hook, or a script an agent just wrote. Exit status 1 when it finds errors.
$ pipx install routeros-lsp # or: uv tool install routeros-lsp $ routeros-lsp --version $ routeros-lsp check scripts/ # exit 1 when there are errors
.rsc script.mikrotik_upload_file, then mikrotik_import_configuration.routeros-skills is 34 agent skills for RouterOS 7: short, task-oriented instructions — what to do, what to avoid — each backed by MikroTik's official documentation as plain Markdown, so your agent looks up the exact command instead of guessing. They are plain SKILL.md folders that Claude Code, Codex, GitHub Copilot and any agent that reads them can use. Built to sit beside MikroTik MCP and routeros-lsp; each works on its own. Listed on skills.sh, where npx skills add wiresage/routeros-skills installs them.

.claude/skills: it lists them, loads the one that fits the task and opens the reference files it needs. Drawn from the session transcript — not a screen recording — and the answer is shortened.The name and description of every skill — nothing more until a task matches.
SKILL.md holds the instructions: order of steps, recipes, pitfalls.
MikroTik's manual as plain Markdown: 373 guides, the full CLI reference and 246 hardware manuals. Every page links to its source.
Every name starts with routeros-. Start with fundamentals: it explains the console conventions and maps the rest. Pick a skill to see what it covers and how much of the manual sits behind it.
$ git clone https://github.com/wiresage/routeros-skills.git $ cd routeros-skills $ scripts/install-skills.sh --target ~/.claude/skills $ scripts/install-skills.sh --list
.rsc scripts it writes.Free, MIT-licensed, runs on your hardware. The model never sees your password — it only sees the tools.
Got a question, an idea, or something you'd like to talk through? Users and contributors are both welcome — whether you're connecting your first router or working on a PR.