Your computer is connected to a Wi-Fi network, but you don't know the password used to connect to this WiFi. Maybe you forgot the password or maybe the network administrator entered it without revealing the actual password to you. And now you would like to connect a second device to the same WiFi but how do you find out what the password is? Most of the time, you can send a password request to the WiFi administrator or you can skip that and find it yourself. The first thing you do is open the command prompt on your computer and retrieve the saved password in one easy step. The technique works on both Mac and Windows PCs. I'll walk you through doing it on a MAC and then on Windows so let's get started.
Find the WiFi Password on Windows
Open the command prompt in administrator mode. Type “cmd” in the Run box, right-click the command prompt icon and choose Run as Administrator (see how). Now enter the following command and hit enter to see the WiFi password.netsh wlan show profile name=labnol key=clear
Remember to replace labnol with the name of your Wireless SSID (this is the name of the Wi-Fi network that you connect your computer to). The password will show up under the Security Setting section (see screenshot). If you would only like to see the password and not the other information, use the findstr command:
netsh wlan show profile name=labnol key=clear | findstr Key
Show the WiFi Password on Mac OS X
Your Mac OS X uses Keychain to store the configuration details of the WiFi network and we can use the BSD command “security” to query anything stored inside Keychain, including the Wi-Fi password. Here’s how:
Open Spotlight (Cmd+Space) and type terminal to open the Terminal window. At the command line, enter the following command (replace labnol with your WiFi name), then enter your Mac username and password to access the OS X keychain and the Wi-FI network password would be displayed on the screen in plain text.
security find-generic-password -wa labnol
Start WLAN AutoConfig (Wlansvc Service)
If you are using this technique to retrieve the WiFi password on a Windows computer but getting an error that says – “The Wireless AutoConfig Service (wlansvc) is not running” – here’s a simple fix:
Click the Windows Start button and type “services.msc” in the Run box to access Windows Services. Here go to the WLAN Autoconfig service and make sure that the status is Running. Else right-click the WLAN AutoConfig service, select Properties and go to Dependencies. Check all the dependencies to make sure they are all running.
That's it for today. I hope I was of some help to you. For more tips, keep checking back. Talk to you again soon!