How to configure a single router as a DHCP server?

In this tutorial we learn that how to configure a router as a DHCP router and providing ip address on your pc by this DHCP server. After reading this article we don’t need a DHCP server to assign ip address on your computers and now we use a router to provide ip addresses on your pc by configured your router which act as dhcp server. But it is more beneficiary in small network instead of a large network because let if your router was damaged by any reason then your all computers will be lost their ip address and you provide ip address again on that computers. It is more difficult in a large network so i suggest you use this configuration method in small network only.

router as dhcp

Now in this article we do ot assign ip on pc. Router will be also provide ip on both the pc automatically because we configured router as a DHCP server by given below codes. After this process will be completed router act same as a DHCP server and provide ip addresses on both the pc.

— System Configuration Dialog —

Continue with configuration dialog? [yes/no]: n

Press RETURN to get started!


Router#configure terminal

Enter configuration commands, one per line. End with CNTL/Z.


Router(config)#hostname R1


R1(config)#interface FastEthernet0/0

R1(config-if)#ip address

R1(config-if)#no shutdown


%LINK-5-CHANGED: Interface FastEthernet0/0, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/0, changed state to up


R1(config)#ip dhcp pool rahul





After that now your router will be configured as a DHCP server and  it able to provide ip address on both the pc.

Now after that we will assign ip address on pc directly through the router. To assign ip on both pc you will be first go into pc and then choose desktop option in it and after that choose Ip configuration option in it.

After that to provide ip address we change ip configuration from static to DHCP and wait for few seconds router will be give ip address on your pc. Also do this same process on other pc and assign ip address on that pc also directly by router. figure given below from pc0

ip configuration

Now to check given ip address is real or fake open command prompt of your pc0 and ping with second computer code and result will be given below.

Packet Tracer PC Command Line 1.0


Pinging with 32 bytes of data:

Reply from bytes=32 time=1ms TTL=128

Reply from bytes=32 time=0ms TTL=128

Reply from bytes=32 time=0ms TTL=128

Reply from bytes=32 time=0ms TTL=128

Ping statistics for

Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),

Approximate round trip times in milli-seconds:

Minimum = 0ms, Maximum = 1ms, Average = 0ms


If you saw this type of result on screen that’s prove that ip will be correct and both the pc will be communicate each other with these ip addresses on it. If you have any type of queries and suggestions solved through comment on post.

39 thoughts on “How to configure a single router as a DHCP server?

  1. You are a very powerful writer. I can easily
    see this in your article. You have a way of writing powerful information that sparks
    much interest.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s