Windows provides the ipconfig
command in order to list and manage the network, IP, DNS, DHCP Default Gateway from the command line. ipconfig command provides different options where DHCP configuration can be changed refreshed. The ipconfig command mostly used to list IP, DNS, DHCP, Gateway, or network information and renew the IP address. But we will explain all parameters of the ipconfig command below.
ipconfig Syntax and Parameters
ipconfig command has very simple syntax like below.
ipconfig PARAMETERS
Parameter | Description |
---|---|
/all | Display all interfaces TCP/IP Configuration |
/displaydns | Display DNS configuration |
/flushdns | Flush/Reset DNS configuration |
/registerdns | Register DNS manually |
/release INTERFACE | Release IP configuration for the specified INTERFACE |
/release6 INTERFACE | Release IPv6 configuration for the specified INTERFACE |
/renew INTERFACE | Renew the INTERFACE IP configuration with DHCP |
/renew6 INTERFACE | Renew the INTERFACE IPv6 configuration with DHCP |
/? | Help information |
Print ipconfig Command Help Information
Even the ipconfig is simple command we may need to list help information. We will provide the /?
parameter which will all parameters and some basic samples about ipconfig.
> ipconfig /?

List IP Configuration
The most popular usecase for the ipconfig is listing the IP configuratin without providing any parameter. This will list information like DNS Suffix, IPv4 and IPv6 address, Subnet Mask and Default Gateway.
> ipconfig
C:\>ipconfig
Windows IP Configuration
Ethernet adapter Ethernet0:
Connection-specific DNS Suffix . : localdomain
Link-local IPv6 Address . . . . . : fe80::557b:67:59aa:dcde%7
IPv4 Address. . . . . . . . . . . : 192.168.142.130
Subnet Mask . . . . . . . . . . . : 255.255.255.0
Default Gateway . . . . . . . . . : 192.168.142.2
We can also list specific adaptor or interface IP configuration by providing the adaptor name. In the following example we list the adaptor IP configuration named Ethernet0
.
> ipconfig Ethernet0
> ipconfig "Local Network Adaptor"
List All and Detailed Network Configuration
In previous step we have listed basic network and IP configuration. We can display detailed information abut IP, DHCP, DNS, NetBIOS and Ethernet interfaces with the /all
parameter.
C:\>ipconfig /all
Windows IP Configuration
Host Name . . . . . . . . . . . . : DESKTOP-HQVAMA3
Primary Dns Suffix . . . . . . . :
Node Type . . . . . . . . . . . . : Hybrid
IP Routing Enabled. . . . . . . . : No
WINS Proxy Enabled. . . . . . . . : No
DNS Suffix Search List. . . . . . : localdomain
Ethernet adapter Ethernet0:
Connection-specific DNS Suffix . : localdomain
Description . . . . . . . . . . . : Intel(R) 82574L Gigabit Network Connection
Physical Address. . . . . . . . . : 00-0C-29-DC-62-6A
DHCP Enabled. . . . . . . . . . . : Yes
Autoconfiguration Enabled . . . . : Yes
Link-local IPv6 Address . . . . . : fe80::557b:67:59aa:dcde%7(Preferred)
IPv4 Address. . . . . . . . . . . : 192.168.142.130(Preferred)
Subnet Mask . . . . . . . . . . . : 255.255.255.0
Lease Obtained. . . . . . . . . . : Wednesday, September 23, 2020 8:22:37 AM
Lease Expires . . . . . . . . . . : Thursday, October 1, 2020 5:18:23 PM
Default Gateway . . . . . . . . . : 192.168.142.2
DHCP Server . . . . . . . . . . . : 192.168.142.254
DHCPv6 IAID . . . . . . . . . . . : 33557545
DHCPv6 Client DUID. . . . . . . . : 00-01-00-01-26-38-28-02-00-0C-29-DC-62-6A
DNS Servers . . . . . . . . . . . : 192.168.142.2
Primary WINS Server . . . . . . . : 192.168.142.2
NetBIOS over Tcpip. . . . . . . . : Enabled
Release DHCP Assigned IP Configuration
DHCP assigned IP configuration likeIP address, IPv6 address, DNS server, Default gateway can be released and cleared with the /release
parameter. We will also provide the interface or adaptor name which is Ethernet0 in this case.
> ipconfig /release Ethernet0
If we just want to release IPv6 configuration we can use the release6
parameter like below.
> ipconfig /release6 Ethernet0
With the following command all interfaces or adaptors starting with the Ethernet will be released.
> ipconfig /release Ethernet*
Renew DHCP Assigned IP Address From DHCP Server
DHCP is used to assign the IP address and provide other network-related configuration to the computers and hosts. We can reset and renew existing DHCP configuration which will reset the assigned IP address and other network configuration like DNS, Default Gateway, Hostname, etc. In order to renew the DHCP assignment, the interface name should be provided the interface names can be listed with the ipconfig command. We will use /renew
parameter in order renew the IP configuration of the interface named Ethernet0
. But in some cases, the adaptor or interface can be named as Local Area Connection
.
> ipconfig /renew Ethernet0

We can also renew the IPv6 configuration byusing the /renew6
parameter and providing the interface or adaptor name like below.
> ipconfig /renew6 Ethernet0