default-router [ip]
Specifies the default gateway IP address to be assigned to DHCP clients in a DHCP pool configuration.
default-router [ip]When to Use This Command
- Configuring a DHCP pool for a LAN segment where clients need a default gateway to reach external networks.
- Setting up DHCP for a VLAN interface to provide clients with the router's IP as the default gateway.
- Assigning multiple default gateways for redundancy in a DHCP pool (though only one is typically used).
- Updating the default gateway in an existing DHCP pool when the router's IP changes.
Command Examples
Basic default-router configuration
default-router 192.168.1.1This command sets the default gateway for DHCP clients to 192.168.1.1. No output is displayed upon successful configuration.
Verifying default-router in DHCP pool
show ip dhcp pool LAN_POOLPool LAN_POOL : Utilization mark (high/low) : 100 / 0 Subnet size (first/next) : 0 / 0 Total addresses : 254 Leased addresses : 10 Pending event : none 1 subnet is currently in the pool : Current index IP address range Leased addresses 192.168.1.1 192.168.1.1 - 192.168.1.254 10 Default router : 192.168.1.1
The output shows the DHCP pool details. The 'Default router' line indicates the gateway assigned to clients. Here it is 192.168.1.1. If missing, clients would not receive a default gateway.
Understanding the Output
The 'default-router' command itself produces no output. To verify, use 'show ip dhcp pool [pool-name]'. In the output, look for the 'Default router' field. It should list the IP address(es) configured. If the field is absent, no default gateway is being assigned, which will prevent clients from reaching outside their subnet. Ensure the IP matches the router's interface IP on that subnet.
CCNA Exam Tips
CCNA exam tip: The 'default-router' command is required for DHCP clients to have a gateway; omitting it is a common misconfiguration.
CCNA exam tip: You can only specify one default-router per DHCP pool; multiple entries are not supported in IOS.
CCNA exam tip: The IP must be in the same subnet as the network statement in the DHCP pool.
CCNA exam tip: Remember that 'default-router' is configured in DHCP config mode, not global config.
Common Mistakes
Mistake 1: Forgetting to configure 'default-router' — clients get an IP but no gateway, causing no internet access.
Mistake 2: Using an IP outside the DHCP pool's subnet — clients will ignore or reject the gateway.
Mistake 3: Typing 'default-gateway' instead of 'default-router' — the command will be rejected.
Related Commands
Practice for the CCNA 200-301
Test your knowledge with hundreds of CCNA practice questions covering all exam domains.
Practice CCNA Questions