8 CMD Commands to Manage (Wireless) Networks in Windows
Whatsapp Pinterest

As a Windows user, the Control Panel and the Settings app can feel quite limiting in what they can do. If you want full and absolute control over your network, meaning access to everything the operating system has to offer, then you’ll have to start using Command Prompt.

Unlock the free "100+ Essential Windows CMD Commands" cheat sheet now!

This will sign you up to our newsletter

Enter your Email

Never used Command Prompt before? Don’t worry. Using it is as simple as typing out the commands you’ll see below. It’s not hard at all and we’ll tell you everything you need to know to get started. But if you’re still unsure, check out our beginner’s guide to Command Prompt A Beginner's Guide To The Windows Command Line A Beginner's Guide To The Windows Command Line The command line lets you communicate directly with your computer and instruct it to perform various tasks. Read More .

If you’re ready to continue, here are some of the most useful commands to know for managing and troubleshooting your home network.


ping is one of the most basic yet useful commands you could know. It tells you whether your computer can reach some destination IP address or domain name, and if it can, how long it takes data to travel there and back again.

Sample usage and output:


The command works by sending out multiple data packets and seeing how many of them return. If some of them don’t return, it’ll tell you (“lost”). Packet loss leads to poor performance in games and streaming, and this is a nifty way to test.

By default it sends 4 packets, each one waiting 4 seconds before timing out. You can increase the number of packets like this:

ping www.google.com -n 10

And you can increase the timeout duration like this (value is in milliseconds):

ping www.google.com -w 6000


tracert stands for Trace Route. Like ping, it sends out a data packet as a way to troubleshoot any network issues you might have, but instead tracks the route of the packet as it hops from server to server. (Learn more about how the internet works The Internet & The World Wide Web Are Not the Same Thing [MakeUseOf Explains] The Internet & The World Wide Web Are Not the Same Thing [MakeUseOf Explains] The two terms "Internet" and "World Wide Web" have been used interchangeably ever since the Internet itself became a household "utility" as common as electricity or cable TV. People talk about "surfing the web" and... Read More ).

Sample usage:


The command outputs a line-by-line summary of each hop, including the latency between you and that particular hop and the IP address of that hop (plus domain name if available).

Why do you see three latency readings per hop? Because tracert sends out three packets per hop, in case one of them gets lost or takes an inordinate amount of time that doesn’t represent your true latency. It’s best practice to average the three.


pathping is similar to tracert except more informative, which means it takes a lot longer to execute. After sending out packets from you to a given destination, it analyzes the route taken and computes packet loss on a per-hop basis.

Sample usage and output:



ipconfig may just be the most-used networking command on Windows. Not only is it useful for the information it provides, but you can combine it with a couple switches to execute certain tasks.

Sample usage and output:


The default output shows every network adapter on your system and how they resolve. The IPv4 Address and Default Gateway details under the Wireless LAN Adapter and Ethernet Adapter sections are the most important to know.

Use this switch to flush your DNS cache:

ipconfig /flushdns

Flushing the DNS cache can help when your internet is working, but a specific website or server is unreachable for some reason (e.g. a website times out and won’t load). Learn more about flushing the DNS cache and why 7 Hidden Windows Caches & How to Clear Them 7 Hidden Windows Caches & How to Clear Them Cached files can take up a lot of bytes. While dedicated tools can help you free up disk space, they might not clear it all. We show you how to manually release storage space. Read More .


Every device that’s compliant with IEEE 802 standards has a unique MAC address (Media Access Control). MAC addresses are assigned by the manufacturer and are stored in the device’s hardware. Some people use MAC addresses to limit which devices can connect to the network 10 Crucial Features to Use in Your Wireless Router Setup at Home 10 Crucial Features to Use in Your Wireless Router Setup at Home Most wireless routers are equipped with a handful of amazing features that you probably aren't taking advantage of. Here are some of the more useful ones to start exploring right now. Read More .

Sample usage and output:


You may see more than one MAC address depending on how many network-related adapters are on your system. For example, Wi-Fi and Ethernet connections would have separate MAC addresses.


nslookup stands for Name Server Lookup. It’s a nifty utility that’s packed with a lot of power, but most users don’t need all of that power. For regular folks like you and me, its main use is finding out the IP address behind a certain domain name.

Sample usage and output:


Note that certain domain names aren’t tied to a dedicated IP address, which means that you may get different IP addresses every time you run the command. This is normal for bigger websites because they spread their workload across many different machines.

If you want to convert an IP address into a domain name, just type it into your browser and see where it leads. Not all IP addresses lead to domain names though, and many IP addresses aren’t reachable over the web.


netstat is a tool for network statistics, diagnostics, and analysis. It’s powerful and complex, but can be simple enough if you ignore the advanced aspects that you don’t need to know about (assuming you aren’t managing a massive business or campus network, for example).

Sample usage and output:


By default, the command shows all “active connections” on your system whether those connections are on LAN or across the internet. An active connection doesn’t mean data is being moved — it could just mean a port that’s open and ready to accept a connection.

Indeed, netstat is mostly useful to regular users for its ability to show port information, and that can come in handy when you need to forward ports What Is Port Forwarding & How Can It Help Me? [MakeUseOf Explains] What Is Port Forwarding & How Can It Help Me? [MakeUseOf Explains] Do you cry a little inside when someone tells you there’s a port forwarding problem and that’s why your shiny new app won’t work? Your Xbox won’t let you play games, your torrent downloads refuse... Read More .

But the command also has about a dozen switches that change what kind of information is displayed, such as the -r switch which shows a routing table instead.


netsh stands for Network Shell. It’s a command that lets you view and configure pretty much every network adapter on your system, in more detail and granularity than any of the preceding commands.

Running the netsh command on its own will shift the Command Prompt into network shell mode. There are several different “contexts” within this shell, including one for routing-related commands, one for DHCP-related commands, and one for diagnostics, among others. But you can use it to run individual commands, too.

To see all network shell contexts:


And to see all commands within a context:


You can drill down one more layer to find all of the subcommands within those commands:


So for example, you can run this command to view all of the wireless network drivers on your system and their properties:

netsh wlan show drivers

It’s an advanced command that’s complex enough to deserve an entire article of its own. Just know that if you want to get real technical with your network configuration, you’ll probably need to use this command line utility.

Other Home Networking Tips

Maybe Command Prompt isn’t necessary for the specific problem you’re having. You should definitely check out these common Windows networking problems 4 Quick Solutions to Windows Network Connection Problems 4 Quick Solutions to Windows Network Connection Problems Read More to see if there’s a solution for you in there.

Then again, everyone should have at least a little bit of Command Prompt experience. It can come in handy when you least expect it. Start with these basic commands every user should know 15 Windows Command Prompt (CMD) Commands You Must Know 15 Windows Command Prompt (CMD) Commands You Must Know The command prompt is still a powerful Windows tool. Here are the most useful CMD commands every Windows user needs to know. Read More .

How comfortable are you with Command Prompt? Got any other networking tips that could prove useful for Windows users? Share with us down in the comments!

Explore more about: Command Prompt, Computer Networks, Wi-Fi.

Enjoyed this article? Stay informed by joining our newsletter!

Enter your Email

Leave a Reply

Your email address will not be published. Required fields are marked *

  1. Praveen
    September 26, 2018 at 8:36 pm

    How can I know Wifi password? Is it possible...

  2. Harshal Patil
    July 26, 2018 at 10:40 am

    The cmd steps worked for me

  3. Harshal Patil
    July 26, 2018 at 10:40 am

    The cmd step worked for me and I also get to see how awesome cmd can be

  4. Mike
    October 31, 2017 at 11:37 pm

    These are all just basic windows networking commands. Why does the headline tout them as wireless commands? I actually thought I was going to learn something when I clicked on the article.

    • yash
      November 14, 2017 at 7:10 am

      Good comand for controll wifi

    • yash
      November 14, 2017 at 7:11 am

      Well comands