Find the Wi-Fi Password for Your Current Network Using the Command Line
If you’re connected to a Wi-Fi network, your computer usually stores this password, so you don’t have to enter it every time. But sometimes you forget this password. To understand what it is, Digital Inspiration indicates that all you have to do is enter a simple command at the command line.
Revealing Wi-Fi password is slightly different on both Windows and Mac. On Windows, you need to open Command Prompt in Administrator Mode. Then enter this command, replacing your Wi-Fi network name with “labnol”:
netsh wlan show profile name = key labnol = clear
On a Mac, open Terminal and enter this command, replacing your Wi-Fi network name with “labnol”:
security find-common-password -ga labnol | grep password
That’s all, now you know the password for the network you are on.
How to get the password of the Wi-Fi network to which you are connected | Digital inspiration