Bridging in MikroTik RouterOS: Connecting Multiple Ethernet Ports
A bridge in networking is a virtual switch that connects multiple interfaces at Layer 2 (the Ethernet/MAC layer). When ports are bridged together, devices connected to any of those ports can communicate directly as if they were all on the same physical switch. This lesson explains when to use bridging, how to create and configure a bridge in RouterOS, and when to use routing instead.
Bridging vs Routing: When to Use Which?
Understanding the difference is fundamental:
Bridging (Layer 2)
- Devices on bridged ports are in the same subnet (e.g., all
192.168.1.x) - Traffic between devices on bridged ports does not go through the RouterOS routing engine
- The bridge acts like a switch — fast, transparent forwarding based on MAC addresses
- Use bridging when you want all ports to act as one LAN
Routing (Layer 3)
- Devices on different interfaces are in different subnets (e.g.,
192.168.1.xand10.0.0.x) - Traffic between subnets is processed by the RouterOS routing engine
- Gives you full firewall control and visibility over inter-subnet traffic
- Use routing when you need to separate traffic (VLANs, security zones, etc.)
Creating a Bridge Interface
In RouterOS v7, creating a bridge is a three-step process:
- Create the bridge interface
- Add member ports to the bridge
- Assign an IP address to the bridge (not to the individual member ports)
Step 1: Create the Bridge
/interface bridge add name=bridge comment=lan-bridgeYou can name it anything. bridge is the common convention for the main LAN bridge.
View the bridge:
/interface bridge printStep 2: Add Ports to the Bridge
Add whichever Ethernet ports you want in the LAN:
/interface bridge port add interface=ether2 bridge=bridge
/interface bridge port add interface=ether3 bridge=bridge
/interface bridge port add interface=ether4 bridge=bridge
/interface bridge port add interface=ether5 bridge=bridgeNotice that ether1 is NOT added — it is kept separate as the WAN port.
View bridge ports:
/interface bridge port printOutput example:
Flags: X - disabled, I - inactive, D - dynamic, H - hw-offload
# INTERFACE BRIDGE HW PVID PRIORITY PATH-COST HORIZON
0 H ether2 bridge yes 1 0x80 10 none
1 H ether3 bridge yes 1 0x80 10 none
2 H ether4 bridge yes 1 0x80 10 none
3 H ether5 bridge yes 1 0x80 10 noneThe H flag means hardware offload is active — the CRS switch chip handles bridging in hardware for maximum performance.
Step 3: Assign an IP to the Bridge Interface
Instead of assigning IPs to ether2, ether3 etc. individually, assign one IP to the bridge:
/ip address add address=192.168.1.1/24 interface=bridgeThis single IP serves as the gateway for all devices connected to any bridged port.
Adding Wireless to the Bridge
To include wireless clients in the same LAN as wired clients:
/interface bridge port add interface=wlan1 bridge=bridge
/interface bridge port add interface=wlan2 bridge=bridgeNow wired (ether2–ether5) and wireless (wlan1, wlan2) devices are all in the same bridge and share the same subnet and DHCP server.
Hardware Offload
On MikroTik devices with a built-in switch chip (most RouterBOARD devices), bridging can be offloaded to the hardware switch chip for much higher throughput than software bridging.
RouterOS enables hardware offload automatically when it can. You can check the status with:
/interface bridge port printLook for the H flag in the output — if present, hardware offload is active.
To explicitly enable or disable hardware offload on a port:
/interface bridge port set 0 hw=yesBridge MAC Address and STP
MAC Address
When you create a bridge, RouterOS assigns it a MAC address (usually borrowed from the first port added). You can set it manually:
/interface bridge set bridge auto-mac=no admin-mac=AA:BB:CC:DD:EE:01Spanning Tree Protocol (STP)
STP prevents bridging loops (which would crash your network). RouterOS supports:
none— no STP (use only when you have no loops possible)stp— classic Spanning Tree Protocolrstp— Rapid STP (faster convergence, recommended)
Set STP mode:
/interface bridge set bridge protocol-mode=rstpFor a simple home/office setup with no redundant links, none works fine. For networks with multiple uplinks, use rstp.
VLAN-Aware Bridging (Brief Overview)
RouterOS v7 bridges support VLAN filtering, which lets you run multiple VLANs on the same physical ports while still using hardware offload. This is a more advanced topic but worth knowing exists:
/interface bridge set bridge vlan-filtering=yesWhen VLAN filtering is enabled, you configure VLAN membership per port using /interface bridge vlan.
Complete Example: 5-Port Home Router Bridge Setup
Here is a typical configuration where ether1 is WAN and ether2–ether5 are LAN:
# Create bridge
/interface bridge add name=bridge protocol-mode=rstp
# Add LAN ports to bridge
/interface bridge port add interface=ether2 bridge=bridge hw=yes
/interface bridge port add interface=ether3 bridge=bridge hw=yes
/interface bridge port add interface=ether4 bridge=bridge hw=yes
/interface bridge port add interface=ether5 bridge=bridge hw=yes
# Add wireless to bridge (if device has wireless)
/interface bridge port add interface=wlan1 bridge=bridge
/interface bridge port add interface=wlan2 bridge=bridge
# Assign IP to the bridge
/ip address add address=192.168.1.1/24 interface=bridge
# Set up DHCP server on bridge
/ip pool add name=lan-pool ranges=192.168.1.100-192.168.1.200
/ip dhcp-server add name=dhcp-lan interface=bridge address-pool=lan-pool disabled=no
/ip dhcp-server network add address=192.168.1.0/24 gateway=192.168.1.1 dns-server=8.8.8.8Troubleshooting Bridges
Check Which Ports Are in the Bridge
/interface bridge port printCheck the Bridge MAC Table (ARP-like Layer 2 Table)
/interface bridge host printThis shows which MAC addresses have been learned on which bridge port.
Check Bridge Status
/interface bridge print detailSummary
Bridging in RouterOS:
- Use when you want multiple ports on the same subnet (acting as a switch)
- Create bridge:
/interface bridge add name=bridge - Add ports:
/interface bridge port add interface=etherX bridge=bridge - Assign one IP to the bridge, not to individual ports
- Enable hardware offload (
hw=yes) for maximum performance - Use RSTP (
protocol-mode=rstp) to prevent bridging loops - Bridge vs route: same subnet = bridge, different subnets = route
