There are several other articles that we have written on various Windows 10 WLAN/Wi-Fi commands that you can execute to perform various important wireless information gathering and management. We will refer to them below. Nevertheless, we wanted to provide a single article with all the pertinent commands and examples in one place.
We have not provided a detail of what every single output line is in every command response. You can dig deeper into these commands and outputs at the the following sites:
That said, let's get started.
First, you will want to open a Command Line (Windows Start> Run> "cmd" - select run as Administrator, usually with a right click) or Powershell (Winodws key+X, the 'A') window.
Both examples shown below (we will continue in the CMD window). Note that if properly run as Administrator, you will be at the C:\WINDOWS\system32> prompt!
Displaying the WLAN/Wi-Fi Interfaces
This is easy:
netsh wlan show interfaces
Example output (I have two interfaces - Wi-Fi is my internal, and Wi-Fi4 is my external)
Both my interfaces were connected to a wireless LAN. If not connected, your output will be different.
For more info on the meaning of signal level - look here: https://www.cellstream.com/reference-reading/tipsandtricks/435-signal-percent-windows
Now that we know the interfaces, what drivers are in play? You find this out with the following command:
netsh wlan show drivers
We can see that the drivers begin to show the WLAN/Wi-Fi capabilities of our interfaces.
Displaying the Nearby WLAN/Wi-Fi Networks
Almost missed this one. Youy can use netsh tpo display all the available networks around you.
Here is the command:
netsh wlan show networks mode=bssid
Here is an example output (I did this one in Powershell and I truncated it for space):
We can however look further into the WLAN/Wi-Fi capabilities with the following command:
netsh wlan show capabilities
Windows WLAN/Wi-Fi Profiles
Every time you connect to a WLAN/Wi-Fi access point, Windows creates a "wireless network profile", and it's stored on your computer.
Storing these profiles is not necessarily a good idea. You can read more on this here: https://www.cellstream.com/reference-reading/tipsandtricks/368-deleting-remembered-wi-fi-networks-in-windows
You can view all these profiles using the following command:
netsh wlan show profiles
Example output (obscured):
Viewing WLAN/Wi-Fi Network Passwords
Now that you know the profiles, and you cannot remember your network security key to connect some other device to a particular Wi-Fi access point, you can use the following command to view your network security keys, but you can only query one profile at a time (replace the "profile_name" with the actual profile name in your list):
netsh wlan show profile name="profile_name" key=clear
Example output (again obscured):
Now this raises some interesting issues. All the WLAN/Wi-Fi access keys are actually on your Windows 10 computer! Plus, as discussed in the article mentioned above, this leads to you inadvertently probing for these networks which could lead to a Man In The Middle attack.
Did you know you can save all the profiles and passkeys?! Here is the command (replace "folder_path" with the path to where you want to save the file):
netsh wlan export profile key=clear folder="folder_path"
Example output (obscured):
Note: the folder must exist for this to work. The outputs are in XML format:
How to Stop Probing for Saved Networks
You can turn off the automatic connection setting which stops sending probes with the following command (replace the "profile_name" with the actual profile name in your list):
netsh wlan set profileparameter name="profile_name" connectionmode=manual
How to Remove Profiles
Another thing you want to do is remove profiles, which will also remove the network password.
Note: If you delete the current network you are connected to, your network connection will drop!
You do this with the following command to remove a particular profile (replace the "profile_name" with the actual profile name in your list):
netsh wlan delete profile name="profile_name"
Or you can remove them all:
netsh wlan delete profile *
We hope this helps Windows users. Feel Free to paruse our other WLAN/Wi-Fi and Windows articles using the tags below.
Also, feel free to comment below as well.