How to Configure DHCP Server on Windows Server: Step-by-Step Guide

Every device connected to a business network needs an IP address. Without one, computers cannot communicate properly with servers, printers, routers, or other network devices.
In a small office with only a few computers, manually assigning IP addresses might seem manageable. But as the network grows, manual configuration becomes time-consuming and increases the risk of mistakes.
This is where DHCP Server on Windows Server becomes useful.
Dynamic Host Configuration Protocol (DHCP) automatically assigns IP addresses and other network settings to client devices. Instead of configuring every workstation individually, administrators can manage network addressing from a central location.
In this guide, we’ll explain how DHCP works, how to install and configure DHCP Server on Windows Server, create scopes, manage IP reservations, integrate DHCP with DNS and Active Directory, and troubleshoot common problems.
The instructions apply to Windows Server 2016, 2019, 2022, and 2025, although some interface details may vary.
1. What Is DHCP and How Does It Work?
DHCP stands for Dynamic Host Configuration Protocol.
Its purpose is to automatically provide devices with the network configuration they need to communicate.
A DHCP server typically assigns:
- An IPv4 address
- A subnet mask
- A default gateway
- DNS server addresses
- A DNS domain suffix
- A lease duration
Without DHCP, administrators would need to enter these settings manually on each device.
Consider an office with 20 computers. Instead of assigning 20 different IP addresses, you can configure a DHCP server to distribute addresses from a predefined range.
When employees connect their computers to the network, DHCP handles the addressing process automatically.
Understanding the DHCP DORA Process
The standard DHCPv4 address allocation process is commonly described as DORA.
D — Discover
A client without an IPv4 address broadcasts a DHCP Discover message to locate available DHCP servers.
O — Offer
A DHCP server responds with an offer containing an available IP address and configuration information.
R — Request
The client requests the offered address, identifying the DHCP server it has selected.
A — Acknowledge
The selected DHCP server confirms the lease by sending a DHCP Acknowledgment.
Once the process completes, the client can use its assigned IP address.
In simplified form:
Discover → Offer → Request → Acknowledge
This process happens automatically when a client needs a new lease. Existing clients may also renew leases without repeating the complete broadcast process.
2. Example Small Business Network
We’ll use the same network design as our Windows Server DNS tutorial.
Imagine a company with 15 employees, one Windows Server domain controller, and several shared network resources.
| Device | IP address |
|---|---|
| Router / default gateway | 192.168.10.1 |
| Windows Server / DNS | 192.168.10.10 |
| File server | 192.168.10.20 |
| Network printer | 192.168.10.50 |
| DHCP client range | 192.168.10.100–199 |
Our example Active Directory domain is:
corp.example.com
The subnet is:
192.168.10.0/24
The subnet mask is:
255.255.255.0
We’ll configure Windows Server DHCP to assign client addresses between:
192.168.10.100 and 192.168.10.199
The router, domain controller, file server, and printer will remain outside the dynamic address pool.
This helps prevent conflicts between dynamically assigned addresses and infrastructure devices.
Important: Before introducing a new DHCP server, check whether your router or another server already distributes IP addresses. Two uncoordinated DHCP services can create serious connectivity problems.
3. Requirements Before Installing DHCP Server
Before starting the configuration, make sure you have:
- A supported Windows Server installation
- Administrator privileges
- A static IP address on the DHCP server
- A planned subnet and DHCP address range
- A working network connection
- Appropriate firewall rules
- Access to Active Directory authorization if the server belongs to an AD domain
For our example, the DHCP server will use:
Hostname: DC01
IP address: 192.168.10.10
Domain: corp.example.com
Should DHCP Run on a Domain Controller?
Windows Server DHCP can run on a domain controller, and this is sometimes done in small environments.
However, larger organizations often separate DHCP from domain controller workloads for security, availability, and operational reasons.
For a small office, the appropriate design depends on the available infrastructure and business requirements.
If DHCP runs on a domain controller, pay particular attention to DNS dynamic update credentials and permissions.
4. How to Install DHCP Server on Windows Server
There are two common methods for installing the DHCP Server role.
Method 1: Install DHCP Using Server Manager
- Open Server Manager.
- Click Manage → Add Roles and Features.
- Select Role-based or feature-based installation.
- Choose the appropriate Windows Server.
- Under Server Roles, select DHCP Server.
- Accept the required management tools.
- Continue through the wizard.
- Click Install.
After installation, complete the DHCP post-installation configuration if Server Manager prompts you to do so.
This may include creating security groups and authorizing the server in Active Directory.
Open the management console through:
Server Manager → Tools → DHCP
Method 2: Install DHCP Using PowerShell
Open PowerShell as Administrator and run:
Install-WindowsFeature DHCP -IncludeManagementTools
Verify installation:
Get-WindowsFeature DHCP
Check the DHCP Server service:
Get-Service DHCPServer
The DHCP Server role should now be installed.
However, installation alone does not mean the server is ready to distribute IP addresses.
You still need to complete authorization where required and configure at least one active scope.
5. Authorizing DHCP Server in Active Directory
In an Active Directory domain environment, Windows DHCP servers must be authorized before they can properly distribute addresses.
Authorization helps prevent unauthorized Windows DHCP servers from operating within the domain.
Authorize DHCP Through the Console
- Open the DHCP management console.
- Expand the server list.
- Right-click your DHCP server.
- Select Authorize.
- Wait briefly.
- Refresh the console and verify the server status.
You need appropriate Active Directory permissions to authorize a DHCP server.
Authorize DHCP Using PowerShell
For our example:
Add-DhcpServerInDC -DnsName "DC01.corp.example.com" -IPAddress 192.168.10.10
Verify authorization:
Get-DhcpServerInDC
The authorized server should appear in the results.
Important: Do not run the Active Directory authorization command on a standalone server that is not part of an AD domain.
Also, DHCP authorization does not prevent every possible rogue DHCP device. A consumer router or another non-Windows device may still distribute DHCP responses unless your network switches and security configuration prevent it.
6. How to Create a DHCP Scope
A DHCP scope defines the range of IP addresses that a DHCP server can distribute to clients on a particular subnet.
For our example, we’ll create the following scope:
| Setting | Value |
|---|---|
| Scope name | Office LAN |
| Network | 192.168.10.0/24 |
| Starting address | 192.168.10.100 |
| Ending address | 192.168.10.199 |
| Subnet mask | 255.255.255.0 |
| Default gateway | 192.168.10.1 |
| DNS server | 192.168.10.10 |
| DNS domain | corp.example.com |
Create a Scope Through DHCP Manager
- Open Server Manager → Tools → DHCP.
- Expand your DHCP server.
- Right-click IPv4.
- Select New Scope.
- Enter
Office LANas the scope name. - Enter the starting IP address:
192.168.10.100. - Enter the ending IP address:
192.168.10.199. - Enter the subnet mask:
255.255.255.0. - Configure exclusions if needed.
- Choose an appropriate lease duration.
- Configure the default gateway.
- Enter the DNS server and domain name.
- Skip WINS configuration unless your environment specifically requires it.
- Activate the scope.
Once activated, the DHCP server can begin distributing addresses to eligible clients.
Create a Scope Using PowerShell
Add-DhcpServerv4Scope `
-Name "Office LAN" `
-StartRange 192.168.10.100 `
-EndRange 192.168.10.199 `
-SubnetMask 255.255.255.0 `
-LeaseDuration 8.00:00:00 `
-State Active
This creates an active scope with an eight-day lease duration.
The scope ID is:
192.168.10.0
Verify the scope:
Get-DhcpServerv4Scope
Before activating a new production scope, ensure no other uncoordinated DHCP server is serving the same client network.
7. Configuring DHCP Options: Gateway, DNS, and Domain Name
Creating an address range is only part of DHCP configuration.
Clients also need additional network settings.
The most important DHCP options for many small businesses are:
| Option | Purpose | Example |
|---|---|---|
| 003 | Router / default gateway | 192.168.10.1 |
| 006 | DNS servers | 192.168.10.10 |
| 015 | DNS domain name | corp.example.com |
Configure DHCP Options Through the GUI
- Open DHCP Manager.
- Expand IPv4.
- Expand your
Office LANscope. - Right-click Scope Options.
- Select Configure Options.
- Enable option 003 Router and enter
192.168.10.1. - Enable option 006 DNS Servers and enter
192.168.10.10. - Enable option 015 DNS Domain Name and enter
corp.example.com. - Apply the changes.
Configure Options Using PowerShell
Set-DhcpServerv4OptionValue `
-ScopeId 192.168.10.0 `
-Router 192.168.10.1 `
-DnsServer 192.168.10.10 `
-DnsDomain "corp.example.com"
Verify the configured values:
Get-DhcpServerv4OptionValue -ScopeId 192.168.10.0
Important DNS Consideration
In an Active Directory environment, domain-joined computers should normally receive internal DNS servers capable of resolving the AD domain.
Avoid assigning public DNS resolvers directly to domain clients as an alternative to internal DNS.
For a complete explanation, read our Windows Server DNS Configuration Guide.
8. DHCP Exclusions vs. Reservations
Exclusions and reservations are two different ways to control IP address assignment.
DHCP Exclusions
An exclusion prevents DHCP from dynamically distributing certain addresses within a scope.
For example, suppose you configured a broad scope covering:
192.168.10.50–199
But you want to keep:
192.168.10.50–99
available for manually configured devices.
You could exclude that range.
PowerShell example for such a broader scope:
Add-DhcpServerv4ExclusionRange `
-ScopeId 192.168.10.0 `
-StartRange 192.168.10.50 `
-EndRange 192.168.10.99
For our actual 192.168.10.100–199 scope, those infrastructure addresses are already outside the dynamic pool, so this exclusion is unnecessary.
DHCP Reservations
A reservation assigns a particular IP address to a device identified by its DHCP client identifier, commonly based on its MAC address.
For example, you might want a network printer to always receive:
192.168.10.150
A reservation can ensure the DHCP server consistently offers that address to the matching client.
In DHCP Manager:
- Expand the appropriate scope.
- Right-click Reservations.
- Select New Reservation.
- Enter a descriptive name.
- Enter the desired IP address.
- Enter the device’s MAC address.
- Select the supported DHCP type.
- Save the reservation.
PowerShell example:
Add-DhcpServerv4Reservation `
-ScopeId 192.168.10.0 `
-IPAddress 192.168.10.150 `
-ClientId "00-11-22-33-44-55" `
-Description "Office Printer"
Replace the sample MAC address with the actual device identifier.
Reservations are useful for printers, scanners, access points, and other devices that benefit from predictable addressing.
However, servers and core infrastructure may still require manually configured static addresses, depending on the network design.
9. Understanding DHCP Lease Duration
A DHCP lease is the period during which a client is allowed to use an assigned IP address.
The DHCP server tracks the lease and can renew it when appropriate.
For a typical office network, an eight-day lease is often a reasonable starting point.
For guest Wi-Fi or networks with frequent device turnover, shorter leases may be useful.
Examples
Stable office network: Several days
Guest Wi-Fi: Several hours to one day, depending on usage
Frequently changing client environment: A shorter lease based on available address capacity
There is no single ideal lease duration for every business.
Change the Lease Duration Using PowerShell
Set-DhcpServerv4Scope `
-ScopeId 192.168.10.0 `
-LeaseDuration 4.00:00:00
This changes the scope lease duration to four days.
A shorter lease does not automatically improve network performance. It simply changes how frequently clients need to renew their address leases.
10. DHCP and DNS Integration
DHCP and DNS perform different functions, but they work closely together.
DHCP provides IP configuration.
DNS translates hostnames into IP addresses.
In an Active Directory environment, keeping DNS records synchronized with DHCP-assigned addresses is particularly important.
Dynamic DNS Updates
Windows DHCP Server can participate in dynamic DNS updates for supported clients.
Depending on your configuration, the DHCP server may update DNS records on behalf of clients.
This can be useful for devices that cannot update their own DNS records.
Configure DNS Updates
In DHCP Manager:
- Right-click IPv4 or the relevant scope.
- Select Properties.
- Open the DNS tab.
- Review the dynamic DNS update settings.
- Choose the update behavior appropriate for your environment.
In Active Directory-integrated zones, secure dynamic updates should generally be preferred.
If DHCP updates DNS records on behalf of clients, configure suitable dedicated DNS update credentials where appropriate.
Avoid giving DHCP unnecessarily broad permissions.
Why This Matters
Imagine a laptop receives:
192.168.10.125
Later, it receives:
192.168.10.142
If its DNS record is not updated, other systems may continue attempting to reach the old address.
Correctly configured dynamic updates help reduce stale DNS information.
11. DHCP Relay: Serving Multiple Subnets
In a simple office, the DHCP server and clients may be on the same subnet.
But larger networks often use multiple VLANs or IP subnets.
For example:
Office VLAN: 192.168.10.0/24
Guest VLAN: 192.168.20.0/24
Management VLAN: 192.168.30.0/24
DHCP Discover messages are normally broadcast within the local subnet.
Routers do not generally forward these broadcasts between subnets automatically.
To provide DHCP service across routed networks, administrators commonly configure a DHCP relay agent, sometimes called an IP helper.
The relay forwards DHCP messages between clients and a DHCP server on another subnet.
Example
Your DHCP server is located at:
192.168.10.10
Guest devices are connected to:
192.168.20.0/24
A DHCP relay on the guest VLAN interface forwards DHCP requests to the server.
The DHCP server must also have a suitable scope for the guest subnet.
Security note: Guest network design should maintain appropriate isolation from internal business resources. Providing DHCP service does not mean guest devices should have unrestricted access to the domain controller or other internal services.
For more information about separating business networks, see our VLANs for Small Business Guide.
12. DHCP Failover and High Availability
What happens if your DHCP server fails?
Existing clients can often continue using valid leases for some time, but new clients and lease renewals may eventually be affected.
Windows Server supports DHCP failover between two compatible DHCP servers.
DHCP Failover Modes
Load Balance Mode
Two DHCP servers share responsibility for servicing clients.
The default load distribution is commonly 50/50.
Hot Standby Mode
One DHCP server normally handles client requests, while the partner provides redundancy if the primary becomes unavailable.
Configuring DHCP Failover
For an environment with two appropriately configured DHCP servers:
- Install the DHCP Server role on both servers.
- Authorize both servers in Active Directory if required.
- Configure the IPv4 scope on the primary server.
- Open DHCP Manager.
- Right-click the IPv4 node or selected scope.
- Select Configure Failover.
- Choose the scope to protect.
- Enter the partner DHCP server.
- Select Load Balance or Hot Standby.
- Configure the relationship settings and complete the wizard.
Do not manually create an identical, independently active scope on the partner before configuring failover.
Windows DHCP failover is designed for two DHCP servers sharing selected IPv4 scopes.
It does not provide the same failover functionality for DHCPv6 scopes.
For many small offices, DHCP failover may be optional. The decision should depend on availability requirements, network design, and recovery objectives.
13. Essential DHCP PowerShell Commands
PowerShell is especially useful when managing DHCP remotely or automating repetitive tasks.
List IPv4 Scopes
Get-DhcpServerv4Scope
View Active Leases
Get-DhcpServerv4Lease -ScopeId 192.168.10.0
View Reservations
Get-DhcpServerv4Reservation -ScopeId 192.168.10.0
Check Scope Statistics
Get-DhcpServerv4ScopeStatistics -ScopeId 192.168.10.0
This helps identify address utilization and available capacity.
View DHCP Options
Get-DhcpServerv4OptionValue -ScopeId 192.168.10.0
Check DHCP Service Status
Get-Service DHCPServer
Export DHCP Configuration
Export-DhcpServer -ComputerName "DC01" -File "C:\DHCP-Backup.xml" -Leases
This exports DHCP configuration and lease information to the specified file.
Ensure the destination directory exists and the command has sufficient permissions.
Important: An exported DHCP configuration is useful for migration and recovery planning, but it should not be your only backup. Protect the export file and include DHCP in your broader server backup strategy.
Our Windows Server Backup Guide explains backup fundamentals for Windows administrators.
14. How to Test DHCP Configuration
After configuring your DHCP server, test it from a Windows workstation.
Step 1: Check the Current Configuration
Open Command Prompt:
ipconfig /all
Look for:
- DHCP Enabled: Yes
- IPv4 Address
- Subnet Mask
- Default Gateway
- DHCP Server
- DNS Servers
- Lease Obtained
- Lease Expires
For our example, the client should receive an address within:
192.168.10.100–199
Step 2: Renew the DHCP Lease
On a test workstation:
ipconfig /release
Then:
ipconfig /renew
Warning: These commands temporarily disrupt the workstation’s network connection. Do not run them casually during an active remote support session, because you may disconnect yourself.
Step 3: Test Connectivity
Check the default gateway:
ping 192.168.10.1
Check the server:
ping 192.168.10.10
A failed ping does not always indicate a DHCP problem because firewalls may block ICMP.
Step 4: Test DNS Resolution
nslookup fileserver.corp.example.com
Verify that the expected DNS server responds and returns the correct address.
Step 5: Check the DHCP Console
On Windows Server, open:
DHCP → IPv4 → Office LAN → Address Leases
Confirm that the workstation appears with the expected address.
15. Common DHCP Problems and How to Fix Them
Problem 1: Client Receives a 169.254.x.x Address
Windows may assign an Automatic Private IP Addressing (APIPA) address when a DHCP client cannot obtain a valid IPv4 lease.
Common causes include:
- DHCP server unavailable
- Scope inactive
- No available addresses
- Firewall restrictions
- VLAN or relay misconfiguration
- Network connectivity problems
Start by checking whether the DHCP service is running and whether the scope has available addresses.
Problem 2: DHCP Scope Is Full
If every available address is leased, new clients may be unable to obtain an address.
Check utilization:
Get-DhcpServerv4ScopeStatistics -ScopeId 192.168.10.0
Possible solutions include reviewing stale leases, adjusting lease duration, or expanding the address pool when the network design permits.
Problem 3: Clients Receive the Wrong Default Gateway
Check DHCP option 003.
An incorrect gateway may allow local network communication while preventing access to other networks or the internet.
Problem 4: Internet Works but Active Directory Does Not
Check DHCP option 006.
If domain-joined computers receive public DNS servers instead of internal Active Directory-aware DNS servers, domain-related services may fail.
Problem 5: Two DHCP Servers Are Responding
This can happen when a router’s DHCP service remains enabled after deploying Windows Server DHCP.
Symptoms may include:
- Clients receiving addresses from different subnets
- Incorrect gateways
- Unexpected DNS settings
- Intermittent connectivity problems
Identify all DHCP servers and ensure that their responsibilities are coordinated.
Do not confuse a properly configured DHCP failover pair with two independent servers accidentally distributing overlapping addresses.
Problem 6: DHCP Server Is Not Authorized
In an Active Directory environment, verify authorization:
Get-DhcpServerInDC
If the server is missing, investigate whether it has been properly authorized.
Problem 7: DHCP Service Errors
Review DHCP Server events in Event Viewer.
You can also inspect the DHCP Server operational and administrative logs where available.
Our Windows Event Viewer Guide explains how to investigate Windows service errors.
16. DHCP Security Best Practices
DHCP is a fundamental network service, but it can also introduce security risks when poorly managed.
Prevent Rogue DHCP Servers
An unauthorized device may distribute incorrect gateway or DNS settings.
Managed switches may support DHCP snooping, which helps restrict DHCP server responses to trusted ports.
Restrict Administrative Access
Only authorized administrators should be allowed to modify DHCP configuration.
Use Appropriate DNS Update Credentials
Where DHCP performs secure DNS updates, configure permissions carefully.
Monitor Scope Utilization
Regularly check available addresses and investigate unexpected changes.
Document Reservations and Exclusions
Maintain a record of important infrastructure devices and their assigned addresses.
Back Up DHCP Configuration
Export DHCP settings and maintain an appropriate server recovery plan.
Keep Servers Updated
Install security updates and review Windows Server support lifecycle information.
Separate Guest and Internal Networks
Use VLANs, firewall rules, and appropriate DHCP scopes to maintain network segmentation.
17. DHCP Configuration Checklist
Before considering the deployment complete, verify the following:
- DHCP Server role is installed.
- Server has a static IP address.
- DHCP is authorized in Active Directory, if applicable.
- Scope range and subnet mask are correct.
- Scope is active.
- Gateway option is correct.
- DNS server addresses are correct.
- DNS domain suffix is configured.
- Infrastructure IP addresses are protected from conflicts.
- Reservations are configured where needed.
- Lease duration is appropriate.
- No uncoordinated DHCP servers exist.
- Clients successfully obtain addresses.
- DNS resolution and network connectivity work.
- Configuration is documented and backed up.
Frequently Asked Questions
Is DHCP Server included with Windows Server?
Yes. DHCP Server is an installable Windows Server role available on supported Windows Server editions.
Can DHCP and DNS run on the same Windows Server?
Yes. Many small businesses run both services on the same server. The appropriate design depends on security, availability, and infrastructure requirements.
Does DHCP require Active Directory?
No. DHCP can operate in a standalone environment without Active Directory. However, Windows DHCP servers in an AD domain environment require appropriate authorization.
What is the difference between a static IP and a DHCP reservation?
A static IP is manually configured on the device. A DHCP reservation is configured on the DHCP server so that a particular client receives a predictable address through DHCP.
What happens when a DHCP lease expires?
A client normally attempts to renew its lease before expiration. If it cannot renew or obtain a valid lease, it may eventually lose the ability to use that address.
Can two DHCP servers work on the same network?
Yes, when properly coordinated. Windows Server DHCP failover is one example. Two independent DHCP servers distributing overlapping addresses without coordination can cause conflicts.
What ports does DHCP use?
DHCPv4 commonly uses UDP ports 67 and 68. DHCPv6 uses UDP ports 547 and 546.
Should I disable DHCP on my router?
If Windows Server DHCP is taking responsibility for the same client network, the router’s DHCP service should normally be disabled or otherwise deliberately coordinated to avoid competing responses.
Do not disable an existing DHCP service until the replacement is correctly configured and ready.
Final Thoughts
Configuring DHCP Server on Windows Server is an important step toward building a reliable and manageable small-business network.
By centrally assigning IP addresses, gateways, and DNS settings, administrators can reduce manual configuration and avoid many common networking mistakes.
A well-designed DHCP deployment should include carefully planned scopes, appropriate lease durations, documented reservations, secure DNS integration, and reliable monitoring.
For organizations using Active Directory, DHCP also works closely with DNS to support consistent client configuration and access to domain resources.
Whether you’re managing a small office with ten computers or a larger Windows Server environment, understanding DHCP will make everyday network administration easier.
The objective is simple: provide every authorized device with the correct network settings, automatically and reliably.