DHCP relay agent

When a device is configured as a DHCP client, it will send a a broadcast packet to discover DHCP servers on the network. Broadcast packets are not forwarded by routers by default, so if a DHCP server is in a different network than the DHCP client, it will not receive the request. Consider the following scenario:

No DHCP server on the segment

The workstation on the left is configured as a DHCP client. R2 on the right is configured as a DHCP server. The workstation sends a DHCP discover packet, but it receives no request, since R1 doesn’t forward the packet to R2 (broadcast packets stay on the local subnet).

To rectify this, we can configure R1 to act as a DHCP relay agent and forward the request to the configured DHCP server. This is done by issuing the ip helper-address DHCP_SERVER_IP_ADDRESS command on its Gi0/0 interface. This command instructs the router to do the following:

  1. watch for DHCP messages on the interface
  2. when a DHCP packet arrives, set the packet’s source IP address to the IP address of Gi0/0
  3. change the destination IP address of the packet from (the broadcast address) to the IP address of the DHCP server and send it to R2
  4. when the answer from the DHCP server is received, change the packet’s destination IP to and send it out its Gi0/0 interface, so that the workstation (which does not have an IP address yet) can receive the answer.

To configure the interface Gi0/0 on R1 to forward DHCP packets, only a single command is needed:

R1(config-if)#ip helper-address

To make sure that the workstation indeed got its IP parameters, we can issue the ipconfig command:


FastEthernet0 Connection:(default port)

Link-local IPv6 Address.........: FE80::2E0:B0FF:FEB3:73E
IP Address......................:
Subnet Mask.....................:
Default Gateway.................:

Download our Free CCNA Study Guide PDF for complete notes on all the CCNA 200-301 exam topics in one book.

We recommend the Cisco CCNA Gold Bootcamp as your main CCNA training course. It’s the highest rated Cisco course online with an average rating of 4.8 from over 30,000 public reviews and is the gold standard in CCNA training: