How to Find Saved WiFi Passwords on Windows, Ubuntu, and Linux: Complete Guide
Forgetting a WiFi password that's already saved on your computer is a common problem. Whether you need to connect another device or share your network credentials with a guest
, retrieving saved WiFi passwords is straightforward on both Windows and Linux systems. This comprehensive guide will show you exactly how to find WiFi passwords on Ubuntu,
other Linux distributions, and Windows operating systems.
How to Find Saved WiFi Passwords on Ubuntu
Ubuntu stores WiFi credentials through NetworkManager, making it easy to retrieve passwords using the command line. Here are multiple methods to access your saved WiFi passwords.
Method 1: Using nmcli Command (Recommended)
The nmcli (NetworkManager Command Line Interface) is the most straightforward method for retrieving WiFi passwords on Ubuntu.
Step 1: List all saved WiFi connections
nmcli connection show
Step 2: Retrieve the password for a specific network
sudo nmcli connection show "YOUR-WIFI-NAME" | grep psk
Replace YOUR-WIFI-NAME with the actual network name from the list. The password will appear in the wireless-security.psk field.
Example:
sudo nmcli connection show "HomeNetwork" | grep psk
Output:
wireless-security.psk: MyPassword123
Method 2: View All Saved WiFi Passwords at Once
To quickly see all saved WiFi passwords on your Ubuntu system:
sudo grep -r '^psk=' /etc/NetworkManager/system-connections/
This command searches through all NetworkManager connection files and displays the stored passwords.
Method 3: Direct File Access
WiFi credentials on Ubuntu are stored as individual files in /etc/NetworkManager/system-connections/.
Step 1: List all saved connections
sudo ls /etc/NetworkManager/system-connections/
Step 2: View a specific connection file
sudo cat /etc/NetworkManager/system-connections/YOUR-WIFI-NAME
The password will be listed in the psk= line under the [wifi-security] section.
Quick One-Liner for Ubuntu
Display all WiFi passwords without connection names:
sudo grep -h '^psk=' /etc/NetworkManager/system-connections/* | sed 's/psk=//'
How to Find Saved WiFi Passwords on Other Linux Distributions
Most modern Linux distributions use NetworkManager, so the Ubuntu methods above will work on Fedora, Debian, Linux Mint, Pop!_OS, and other distributions.
For Arch Linux and Manjaro
The process is identical to Ubuntu:
sudo nmcli connection show "WIFI-NAME" | grep psk
For Distributions Without NetworkManager
If your Linux distribution uses a different network manager like wicd or ConnMan, you'll need to check their respective configuration directories:
For wicd:
sudo cat /etc/wicd/wireless-settings.conf
For wpa_supplicant (manual configuration):
sudo cat /etc/wpa_supplicant/wpa_supplicant.conf
How to Find Saved WiFi Passwords on Windows
Windows provides both graphical and command-line methods to retrieve saved WiFi passwords.
Method 1: Using Command Prompt (All Windows Versions)
This method works on Windows 7, 8, 10, and 11.
Step 1: Open Command Prompt
- Press
Win + R, typecmd, and press Enter - Or search for "Command Prompt" in the Start menu
Step 2: List all saved WiFi networks:
netsh wlan show profiles
Step 3: Retrieve the password for a specific network
netsh wlan show profile name="YOUR-WIFI-NAME" key=clear
Replace YOUR-WIFI-NAME with the network name from the previous list. Look for the "Key Content" field under "Security settings" to find your password.
Example:
netsh wlan show profile name="HomeNetwork" key=clear
Method 2: Using PowerShell (Windows 10/11)
PowerShell offers a more streamlined approach:
View all WiFi passwords at once:
(netsh wlan show profiles) | Select-String "\:(.+)$" | %{$name=$_.Matches.Groups[1].Value.Trim(); $_} | %{(netsh wlan show profile name="$name" key=clear)} | Select-String "Key Content\W+\:(.+)$" | %{$pass=$_.Matches.Groups[1].Value.Trim(); $_} | %{[PSCustomObject]@{ PROFILE_NAME=$name;PASSWORD=$pass }} | Format-Table -AutoSize
Method 3: Using Windows Settings GUI (Windows 10/11)
For Windows 11:
- Open Settings (
Win + I) - Navigate to Network & Internet → WiFi
- Click on "Manage known networks"
- Select the network you want
- Click "View WiFi security key"
- Enter your Windows password when prompted
- The password will be displayed
For Windows 10:
- Open Settings → Network & Internet → WiFi
- Click "Manage known networks"
- Select the network and click "Properties"
- Check "Show characters" under Network security key
Method 4: Using Control Panel (Legacy Method)
- Open Control Panel → Network and Sharing Center
- Click on your active WiFi connection
- Click "Wireless Properties"
- Go to the "Security" tab
- Check "Show characters" to reveal the password
Security Considerations
When retrieving WiFi passwords, keep these security best practices in mind:
- Elevated Privileges Required: Both Linux and Windows require administrator/sudo access to view saved passwords, which is a security feature to prevent unauthorized access
- Protect Your Credentials: Never share WiFi passwords over unsecured channels like email or text messages
- Regular Password Updates: Change your WiFi password periodically for better security
- Use Strong Passwords: Ensure your WiFi network uses WPA2 or WPA3 encryption with a strong password
Troubleshooting Common Issues
Ubuntu/Linux Issues
Problem: "Permission denied" error Solution: Make sure to use sudo before your commands
Problem: NetworkManager not installed Solution: Install NetworkManager:
sudo apt install network-manager
Problem: Empty results when searching for passwords Solution: The network might not be saved. Reconnect to the network and save the credentials.
Windows Issues
Problem: "The wireless local area network interface is powered down" Solution: Enable your WiFi adapter in Device Manager
Problem: Profile not found Solution: Ensure you're typing the network name exactly as it appears in the profile list, including spaces and capitalization
Conclusion
Retrieving saved WiFi passwords is a simple process on both Linux and Windows systems. Ubuntu and other Linux distributions make use of NetworkManager's nmcli command or direct file access, while Windows users can leverage the netsh command or built-in Settings app. Whether you're a system administrator, power user, or just someone who forgot their WiFi password, these methods provide quick and reliable solutions.
Remember to always handle network credentials responsibly and maintain good security practices to keep your wireless network protected.
________
By Azzani
Discussion 1
thnx bro
Leave a Comment