DOS/Windows IP commands are used to perform various tasks, such as assigning an Internet Protocol (IP) address to a network interface or configuring network interface parameters. This article includes just a few of the types of commands available.
Common IP Commands for Windows and DOS
Below you will find a list of the most commonIP adressCommands for Windows and DOS. These includeipconfig, trace ruta, netstat, arp, ruta,host name, control network connections, and other popular DOS and Windows Internet Protocol commands.
Description | DOS/Windows IP command |
---|---|
connection settings | ipconfig / all |
DNS cache information | ipconfig /displaydns |
Release all connections from IP addresses | ipconfig /release |
Release IPv6 connections | ipconfig /release6 |
Renew all IP address connections | ipconfig/refresh |
Renew IPv6 connections | ipconfig /renovar6 |
Re-register DNS connections | ipconfig /registerdns |
Change/Modify DHCP Class ID | ipconfig /setclassid |
Change/Modify DHCP Class ID for IPv6 | ipconfig /setclassid6 |
Network connections | control network connections |
network setup wizard | netsetup.cpl |
connectivity test | ping whatismyip.com |
trace route | track |
TCP/IP protocol sessions | netstat |
Local Route | ruta |
Resolved MAC addresses | arp |
Computer name currently on | host name |
DHCP class information | ipconfig /showclassid |
DHCP class information for IPv6 | ipconfig /showclassid6 |
Name server lookup | nslookup whatismyip.com |
Clear DNS records | ipconfig /flushdns |
Display information for all compartments | ipconfig /all bays |
Shows the available options | ipconfig /? |
What are IP commands used for?
IP commands are tools that Linux network administrators use to configure the network environments in which they work. There are IP DOS commands to verify connectivity, seeDNScaches, and much more.
To check your public IP, go to theWhat is my IP address?home page and you will find your IPv4 and IPv6 addresses.
Definition of IP commands
If you're not familiar with each IP command and what they do, explore these simple explanations to get an idea of how each command is used.
ipconfig / all
Heipconfig / allThe command displays all the information about your network adapter. It helps configure your connection by providing important details about the physical address, DHCP and DNS servers, subnet mask, default gateway, and more. You can also view your IPv4 and IPv6 address with this command, assuming you have an IPv4 and IPv6 address.
ipconfig /displaydns
Heipconfig /displaydnsThe command flushes your computer's DNS resolver cache. The cache essentially keeps track of your activity so you can get to a site faster next time; take note of previously visited domain names and IP addresses. He/displaydnsThe command displays the records name, record type, time to live, section, and A records for the DNS resolver cache.
ipconfig /release
Heipconfig /releaseThe command displays network data, but is especially useful if you need to reset or release IP address connections. When you allow the DHCP protocol, you send DHCP requests from that server, which means that the DHCP servers will no longer be contacted for the assigned IP addresses. The command comes from the IP address of the network adapter, so the request only allows use with the DHCP network adapter.
ipconfig /release6
Heipconfig /release6command, like the/releasecommand, resets or releases IPv6 connections.
ipconfig/refresh
Heipconfig/refreshThe command applies to all adapters within a system, as long as it is DHCP. Renews IPv4 and IPv6 addresses.
ipconfig /renovar6
Heipconfig /renovar6The command is a variation of/renewcommand that renews IPv6 addresses.
ipconfig /registerdns
Heipconfig /registerdnsThe command creates or updates records within your DNS record. Manually log the DHCP release if it doesn't happen on its own. The command also helps to troubleshoot DNS names on the computer.
ipconfig /setclassid
Heipconfig /setclassidThe command allows you to assign a class ID to a system adapter. You can specify which class ID in the command, but this is the general parameter to assign the ID to. It also removes class IDs in certain cases.
ipconfig /setclassid6
Heipconfig /setclassid6The command works the same as the/setclassidcommand, except that it works only with IPv6 addresses and class IDs.
control network connections
Hecontrol network connectionsThe command opens the Microsoft Windows Dial-up and Network Connections window, allowing users to access all their network connections with a single command.
netsetup.cpl
Henetsetup.cplThe command opens the Network Setup Wizard, which sets permissions on folders, adds registry keys, changes protocols, and adjusts other aspects of the system to ensure that the device works on the network.
ping.whatismyip.com

Hewhistledomainis a command line request that uses a signal to check with a host server for availability and response time. It uses Internet Control Message Protocol echo messages to determine whether or not the host on the network is up and the number of packets lost in delivery.
track
Hetrackcommand is another command line utility that traces the path an IP address takes to its destination. It monitors the packet from the local computer to the destination IP or domain, showing the path to assess the time it took to arrive. The command is useful for troubleshooting connection issues.
netstat
Henetstatcommand is a network utility that monitors and evaluates TCP/IP protocol sessions and connections over the network. You can display incoming and outgoing connections, routing tables, usage statistics, and more, including local and remote IP addresses and ports. Astrack, helps troubleshoot connection issues or set up a solution.
ruta
HerutaThe command allows you to manually enter data into the network routing tables, splitting the host routes and the network routes via the destination network address.
arp
HearpThe command displays the ARP entries by hostname. Accepts hosts identified by name or by number. The command also modifies and displays the Internet-to-adapter address translation tables.
host name
Hehost nameThe command simply displays the name of the system you are currently using. You can also use the command to rename the host.
ipconfig /showclassid
Heipconfig/showclassidThe command displays all the DHCP class IDs allowed for a given adapter. It helps when setting a different class ID because it tells you the parameters or limits for a certain adapter.
ipconfig /showclassid6
Heipconfig/showclassid6The command is the same as the/showclassidcommand, only limited to IPv6 address data.
nslookup whatismyip.com
HenslookupThe command, or nameserver lookup command, obtains information from nameservers in a DNS service. It parses any address entries that are cached on your DNS server, then returns information such as the current DNS server you are using, the domain URL, and IP addresses, both IPv4 and IPv6.
ipconfig /flushdns
Heipconfig /flushdnsThe command flushes the DNS cache, which is useful for troubleshooting DNS or removing bad domain information from the cache. It then refreshes memory during browsing or daily activity, giving you an accurate cache since bad information has been removed.
ipconfig /all bays
Heipconfig /all baysThe command displays the same data as theipconfigcommand, simply without any parameters. If you have multiple compartments, it displays the information for all of them.
ipconfig /?
Heipconfig /?command helps the user by showing all the available commands and the best way to use them. If you're having trouble knowing which IP command to use for which task, this command is especially useful.
How to use the IP command
To use any of the IP commands listed above, open a command prompt on your Windows computer. You can do it by following these steps:
- Go to your computerBeginmenu.
- Open command prompt by typingcmdon the menu.
- Enter the IP command you want to use and pressGet into.
You can enter as many commands at the command prompt as you need to get the information or functionality you're looking for.
How to monitor and manage IP addresses
IP Address Management, or IPAM, is the best way to monitor and manage IP addresses and their connections. With IPAM, users have more control over their networks. It simplifies the process of assigning IPv4 and IPv6 addresses, as well as the addresses themselves, promoting easy IP maintenance.
IP address management can occur in a number of ways. Subnetting is a popular option; it creates logical subdivisions of larger networks to simplify the networks and make them more cohesive. You can also use IP address managers, which are applications that integrate with the IP address structure and fully manage IP address functionality on a network. You can track and manage IP addresses, configure them with DHCP or DNS servers, and automate requests for static IP addresses.
If you don't need the full capabilities of an IP address manager, aip address trackeralso provides some of the same services. They can sniff IPs and detect potential IP conflicts, log events, and monitor subnets.
Using these tools, as well as the IP commands at your disposal, helps keep your IP addresses and networks properly connected and up and running.
Solving connection problems using IP commands
ipconfigywhistleare probably the two most used commands in the list above. The ping and ipconfig commands allow you to quickly troubleshoot network connectivity. If you cannot connect to a server on your local network or access the Internet, open a DOS prompt by going to Start and typingcmdin the search box. Then press Enter.
After this, writeipconfigand view your IP address information. Make sure the information displayed is correct. For example, you could see IP 192.168.1.122,subnet255.255.255.0, yDefault Gateway192.168.1.1. If this is the case, try pinging the gateway, which is probably your router. Write onwhistle192.168.1.1.
If you get a response, the device you are on is connected to the local network. If you don't get a response from the gateway or router and your IP address looks weird, like 169.254.0.0, then the device you're on doesn't have a legitimate IP address. At the command prompt, typeipconfig /releaseand press Enter, then typeipconfig/refresh. Once the IP has been renewed, check again to see if the IP looks normal.
In conclusion, these and other System Internet Protocol commands are command line tools to help ensure our device's connectivity can be fixed with a few simple tasks. If you need other IP commands, please read aboutLinux IP commands,Comandos IP Unix,VMS IP Commands, yTCP/IP commands.
FAQs
IP commands for DOS/Windows? ›
First, click on your Start Menu and type cmd in the search box and press enter. A black and white window will open where you will type ipconfig /all and press enter. There is a space between the command ipconfig and the switch of /all. Your ip address will be the IPv4 address.
What is the DOS command for IP address? ›First, click on your Start Menu and type cmd in the search box and press enter. A black and white window will open where you will type ipconfig /all and press enter. There is a space between the command ipconfig and the switch of /all. Your ip address will be the IPv4 address.
How to set IP address in DOS? ›- At the Start screen, type cmd.
- Command Prompt should appear in the Search screen. Click Command Prompt.
- A command prompt window will open. ...
- Type ipconfig /renew to get a new IP address.
- Type exit to exit the command prompt.
- Open the Command Prompt. a. Click the Start icon, type command prompt into the search bar and press click the Command Prompt icon.
- Type ipconfig/all and press Enter.
- The IP Address will display along with other LAN details.
- From the desktop, navigate through; Start > Run> type "cmd.exe". A command prompt window will appear.
- At the prompt, type "ipconfig /all". All IP information for all network adapters in use by Windows will be displayed.
- Type “cmd” to bring up the Command Prompt.
- Open the Command Prompt.
- Type “ping” in the black box and hit the space bar.
- Type the IP address you'd like to ping (e.g., 192.XXX.X.X).
- Review the ping results displayed.
- Go to "Start > Run" and type " cmd " (no quotes), then select "OK"
- Type " ipconfig /release " (no quotes) and press "Enter"
- Once the prompt returns, type " ipconfig /renew " (no quotes), then hit "Enter,"
- Finally, type " exit " (without quotes) then press "Enter" to close the window.
- Select Start > Settings > Network & internet > Wi-Fi and then select the Wi-Fi network you're connected to.
- Under Properties, look for your IP address listed next to IPv4 address.
On an Android/tablet
Go to your Wifi network settings, then select the network you're connected to. You'll find your IP address along with the other network information.
- Go to Settings → Network & internet on the tablet and select Wi-Fi.
- Tap the name of active network and expand the Advanced section.
- Find the Network details field with the local IP address.
How can I get a list of all IP addresses? ›
On Linux, type the command “ifconfig” and press Return. On Windows, type the command “ipconfig” and press Return. Get more information by typing the command “arp -a.” You should now see a basic list of the IP addresses for devices connected to your network.
Which command displays all IP settings? ›The ipconfig command displays the basic IP addressing information for each network interface on the Windows system. This information includes both the IP address and subnet mask.
How to find unknown IP address with cmd? ›Type "ipconfig" in the command prompt and hit enter. It will display your router's IP address in the Default Gateway.
How do I manually set my IP address? ›- Go to your Android Settings.
- Navigate to Wireless & Networks.
- Click on your Wi-Fi network.
- Click Modify Network.
- Select Advanced Options.
- Change the IP address.
- Select Start , then select Settings > Network & Internet .
- Do one of the following: For a Wi-Fi network, select Wi-Fi > Manage known networks. ...
- Under IP assignment, select Edit.
- Under Edit IP settings, select Automatic (DHCP) or Manual. ...
- When you're done, select Save.
- Open “Settings” and select “Connections” > “Wi-Fi.”
- Select the gear icon which appears beside your current network.
- Select “IP settings” > “Static.”
- Input your static IP address.
- Select “Save.”
The PING command is a standard MS-DOS command that allows you to view the computer name and the IP address of an endpoint computer.
How to ping IP with port in cmd? ›- $ telnet <server_ip_address> <server_port_number> $ telnet <server_domain_name> <server_port_number> ...
- $ sudo apt install telnet. ...
- $ telnet 172.67. ...
- $ nmap -p <server_port_number> <server_ip_address> $ nmap -p <server_port_number> <internet_domain_name>
Hold down the Windows key and the R key at the same time to open the Run Prompt window, type "cmd" into the bar, then click OK or press Enter. In the Command Prompt window, type "ping" followed by the destination — either an IP address or a domain name, then press Enter.
What is IP default network command? ›The ip default-network command is another way of indicating a default route. By issuing the command ip default-network 198.15. 15.0 for example, what you are telling the router is “if you have a route to this destination, then the next hop IP address to get to this destination should become a candidate default route”.
How do I assign an IP address to a device? ›
- Open the Google Home app .
- Tap Favorites Wifi Settings. Advanced Networking.
- Tap DHCP IP reservations. Add IP reservations .
- Tap the device for which you'd like to assign a static IP.
- Enter a static IP address, then tap Save .
- IPCONFIG. ...
- NSLOOKUP. ...
- HOSTNAME. ...
- PING. ...
- TRACERT. ...
- NETSTAT. ...
- ARP(Address Resolution Protocol) ...
- SYSTEMINFO.
In an open command line, type ping followed by the hostname (for example, ping dotcom-monitor.com). and press Enter. The command line will show the IP address of the requested web resource in the response. An alternative way to call Command Prompt is the keyboard shortcut Win + R.
How to find IP address on Windows 10 without using command prompt? ›- Click the Start icon and select Settings.
- Click the Network & Internet icon.
- To view the IP address of a wired connection, select Ethernet on the left menu pane and select your network connection, your IP address will appear next to "IPv4 Address".
- Go to the command prompt.
- Type ipconfig.
- Then, type netstat to populate a list of all the port numbers.
Type CMD in the search box and click Run as Administrator from the menu. Enter the net view command to view devices connected to your network You will then see a list of devices connected to your network in the output.
What is the command to see all devices on a network? ›To see all of the devices connected to your network, type arp -a in a Command Prompt window. This will show you the allocated IP addresses and the MAC addresses of all connected devices.
How to find someone else's IP? ›Starting with the simplest way to find someone's IP address is to use one of the many IP lookup tools available online. Resources such as WhatIsMyIPAddress.com or WhatIsMyIP.com offer tools to enter an IP address and search for its free public registry results.
What is the netstat command? ›The netstat command generates displays that show network status and protocol statistics. You can display the status of TCP and UDP endpoints in table format, routing table information, and interface information. netstat displays various types of network data depending on the command line option selected.
What is the difference between ipconfig and ifconfig commands? ›Functionality: The ipconfig command displays all the currently connected network interfaces whether they are active or not. On the other hand, the ifconfig command displays only the enabled network interfaces that are connected to the system.
What is the difference between ipconfig and ipconfig all commands? ›
ipconfig/all: It gives the full configuration of the system. ipconfig/registerdns: This command refreshes all DHCP leases and reregisters the DNS names. ipconfig/displaydns: It displays the information that is stored in the DNS Resolver cache. It has all the DNS information that has been used earlier.
How do you check a IP address is valid or not in cmd? ›Click Start -> Run, type cmd and press Enter, and then type ping 192.168. 1.1 at the prompt window and press Enter. 1. If the result shown as below, it means the IP address is correct and can connect to the router.
How do I unmask my IP address? ›Type "ipconfig /release" (without quotes) at the prompt in the Command Prompt window that appears. Press the "Enter" key. To unhide your IP address, type "ipconfig /renew" (without quotes) to renew the IP address, then press the "Enter" key.
How do I find my network IP address? ›- Select Start > Settings > Network & internet > Wi-Fi and then select the Wi-Fi network you're connected to.
- Under Properties, look for your IP address listed next to IPv4 address.
Type in "cmd" to display the Command Prompt App. 3. On the Command Prompt window, type in ipconfig and press [Enter].
What is my local IP address? ›To check IP address of the local network on the Android device: Go to Settings → Network & internet on the tablet and select Wi-Fi. Tap the name of active network and expand the Advanced section. Find the Network details field with the local IP address.
How do I find my IP address in terminal? ›- For wired connections, enter ipconfig getifaddr en1 into the Terminal and your local IP will appear.
- To see your public IP address in the Mac Terminal, type curl ifconfig.me and your public IP will display.
Type the command "arp -a" to view the list of all IP addresses connected to your network. This will also display the MAC address and the allocation type (static and dynamic) of all your network devices. Type "nslookup" followed by any IP address obtained through the "arp" command in the previous step.
How can I find the IP address of a device? ›Private IP Address: Mobile Devices
Go to About Device > Status. Scroll down and look for the IP Address.
- Go to the command prompt.
- Type ipconfig.
- Then, type netstat to populate a list of all the port numbers.
What is the DOS command to list network connections? ›
- IPCONFIG. The IPCONFIG network command provides a comprehensive view of information regarding the IP address configuration of the device we are currently working on. ...
- NSLOOKUP. ...
- HOSTNAME. ...
- PING. ...
- TRACERT. ...
- NETSTAT. ...
- ARP(Address Resolution Protocol) ...
- SYSTEMINFO.
The netstat command, which is used for displaying the active connections and ports which are connected to the current machine. The nslookup command, which is used for diagnosing the Domain Name System (DNS) infrastructure. The getmac command, which is used to find a computer's MAC address.
What are local IP codes? ›A Local IP address is the identifier (IPv4 or IPv6) that is assigned to your laptop, PC, mobile and any other device within your local network. It is not visible to the outer world, but it is required in order to use the internet.
What is the difference between IP and local IP? ›External and local IP addresses both serve the same purpose, the difference is scope. An external or public IP address is used across the entire Internet to locate computer systems and devices. A local or internal IP address is used inside a private network to locate the computers and devices connected to it.
How to find your IP address without Command Prompt? ›- Click the Start icon and select Settings.
- Click the Network & Internet icon.
- To view the IP address of a wired connection, select Ethernet on the left menu pane and select your network connection, your IP address will appear next to "IPv4 Address".
The netstat command generates displays that show network status and protocol statistics. You can display the status of TCP and UDP endpoints in table format, routing table information, and interface information. netstat displays various types of network data depending on the command line option selected.
What is the nslookup command? ›The nslookup command queries internet domain name servers in two modes. Interactive mode allows you to query name servers for information about various hosts and domains, or to print a list of the hosts in a domain. In noninteractive mode, the names and requested information are printed for a specified host or domain.