If your have a WiFi connection, how do you find out if your computer is connected to WiFi or not? The command netsh interface is used to find your WiFi connection status from command prompt.
Execute the below command to know WiFi connection status
netsh interface show interface | findstr /C:"Wireless" /C:"Name"
Example on my Windows 7 computer
C:>netsh interface show interface | findstr /C:"Wireless" /C:"Name"
Admin State State Type Interface Name
Enabled Connected Dedicated Wireless Network Connection
As you can see, the command shows that Wifi connection is connected when we ran the command.
If the computer has WiFi enabled, but not connected to any network, then the command output would be like below.
C:>netsh interface show interface | findstr /C:"Wireless" /C:"Name"
Admin State State Type Interface Name
Enabled Disconnected Dedicated Wireless Network Connection
If the Wifi is disabled, then the output would be
C:>netsh interface show interface | findstr /C:"Wireless" /C:"Name"
Admin State State Type Interface Name
Disabled Disconnected Dedicated Wireless Network Connection
This command helps to know the status manually. However if we want to know the status in a script, we would need to refine the command further.
Adding users from command line is much easier than going through the UI. It saves…
Do you want to delete a directory from Windows command prompt(CMD)? This post explains how…
We can kill a process from GUI using Task manager. If you want to do…
Chrome is definitely the stable browser compared to other ones and it has been my…
Windows has multiple command line utilities that can help find the version of the Windows…
There are multiple ways to check whether a Windows computer is running 32-bit OS or…
View Comments
netsh interface show interface | findstr /C:"Wireless" /C:"Name"
that does nothing??
David, the command works! Make sure copying the command is not messing up the quotes. Try typing in the command if it still doesn't work.
try
netsh interface show interface | findstr /C:"Wi-Fi" /C:"Name"
In some cases you may need to change C:"Wireless" to C:"Wi-Fi"
Thanks your suggestion worked.
This will wireless/wifi status regardless if your computer says wifi or wireless:
netsh interface show interface | findstr /i "wifi wireless"
My Wi-Fi is turned on in the Settings but the panel at bottom corner when the network icon is clicked shows it as turned off and does not show any networks. What to do? Thanks.
Windows 10:
netsh interface show interface | findstr /C:”WiFi” /C:”Name”
i.e. no hyphen in WiFi