See Saved WiFi Passwords in Kali Linux (and Any Linux): 4 Ways

Logeshwaran
—

To see a saved Wi-Fi password in Kali Linux, or any Linux that uses NetworkManager, open a terminal and run nmcli device wifi show-password for the network you are connected to, or sudo nmcli -s -g 802-11-wireless-security.psk connection show "NetworkName" for any network you have saved. Prefer clicking? In Kali's default Xfce desktop, right-click the network icon → Edit Connections → pick the network → Wi-Fi Security → check Show password. And where are Wi-Fi passwords stored on Linux? In plain text, one file per network, in /etc/NetworkManager/system-connections/. The surprise for most people is that last part: the password is not encrypted on disk. It is protected only by file permissions, which is why you need sudo to read it, and why anyone with root on the machine can read every network it has ever joined.

Ethan needed this on a Tuesday. A client's office router had been set up years ago, nobody remembered the Wi-Fi password, and the only device still connected was the Kali laptop Ethan uses for network checks. One command later he had the password and a QR code the new staff could scan. Jake, who is learning Linux on an old laptop, asked the obvious follow-up: "If it's that easy, can I see my neighbor's password?" No. Every method on this page shows passwords for networks your own machine has already joined with the right password. Nothing here recovers a password you never had, and that is exactly how it should be.

⚡ Quick Answer

• Connected right now → nmcli device wifi show-password. Shows the SSID, password and a QR code. Details.

• Any saved network → nmcli connection show to list names, then sudo nmcli -s -g 802-11-wireless-security.psk connection show "Name". Details.

• All of them at once → sudo grep -r '^psk=' /etc/NetworkManager/system-connections/. Where they are stored.

• No terminal → network icon → Edit Connections → network → Wi-Fi Security → Show password. GUI steps.

Only works for networks this machine has joined. It does not reveal passwords for networks you have never connected to.

Everything below works the same on Kali, Ubuntu, Debian, Fedora, Linux Mint and most other desktop distributions, because they all use NetworkManager. The rare exceptions are covered near the end.

See saved Wi-Fi passwords with nmcli (the fastest way)

nmcli is NetworkManager's command-line tool and is installed on Kali by default. Three commands cover every case.

The network you are connected to now

nmcli device wifi show-password

The output shows the SSID, the security type and the password, followed by a QR code drawn in the terminal. Point a phone camera at it and the phone joins the network without typing anything. That is how Ethan got the client's new staff online in a minute. If NetworkManager asks for authentication, run it with sudo.

Any network you have saved

First list the saved connections; the NAME column is what you need:

nmcli connection show

Then ask for the stored key of one of them. The -s flag means "show secrets", and -g prints just the value:

sudo nmcli -s -g 802-11-wireless-security.psk connection show "Office-5G"

Use quotes if the name has spaces. If nothing prints, the connection is not a WPA-Personal network (see the enterprise section below), or the password is stored in your desktop keyring rather than in the system file, which the GUI method handles.

Every saved network with its password

for c in $(nmcli -t -f NAME,TYPE connection show | awk -F: '$2=="802-11-wireless"{print $1}'); do
  printf '%s: ' "$c"; sudo nmcli -s -g 802-11-wireless-security.psk connection show "$c"
done

This loops through every Wi-Fi connection and prints its name and password. (Names containing spaces break the simple loop; the file method below handles those cleanly.)

Where Linux stores Wi-Fi passwords

NetworkManager keeps one file per saved network in /etc/NetworkManager/system-connections/. On current versions the files end in .nmconnection. Each is a short text file, and the password sits in the [wifi-security] section on a line starting with psk=:

sudo ls /etc/NetworkManager/system-connections/
sudo cat "/etc/NetworkManager/system-connections/Office-5G.nmconnection"

# or every password at once:
sudo grep -r '^psk=' /etc/NetworkManager/system-connections/

The files are owned by root with permissions 600, so only root can read them. That is the entire protection. The password itself is stored as plain text, not encrypted or hashed, because NetworkManager has to hand the real password to the Wi-Fi card every time it connects. This matters for three reasons:

  • Anyone with sudo on your machine can read every Wi-Fi password it has saved. On a shared or lent laptop, that includes the other user.
  • A backup of /etc contains your Wi-Fi passwords. Treat it accordingly.
  • Booting from a live USB gives root access to the disk unless the disk is encrypted. Full-disk encryption, offered by the Kali installer, closes that gap.

If you are new to the commands above, the plain-English guide to sudo and apt explains what sudo is doing and why it asks for your password.

See a saved Wi-Fi password without the terminal

Kali's default Xfce desktop (and anywhere with nm-connection-editor)

  1. Right-click the network icon in the top panel and choose Edit Connections. (Or run nm-connection-editor.)
  2. Double-click the Wi-Fi network you want.
  3. Open the Wi-Fi Security tab.
  4. Check Show password. You may be asked for your login password first.

GNOME (Kali GNOME edition, Ubuntu, Fedora)

  1. Open Settings → Wi-Fi (or Network).
  2. Click the gear icon next to the network. For the network you are on, you can also click the menu at the top and choose Share Network or Show Wi-Fi Network, which displays the password and a QR code.
  3. Open the Security tab and click the eye icon or check Show password.

KDE Plasma

System Settings → Connections (or Wi-Fi & Networking) → select the network → Wi-Fi Security tab → click the eye icon in the password field. Plasma may ask for your KDE Wallet password if secrets are stored there.

Not sure which desktop you have? Kali ships Xfce by default; the desktop environment guide shows how to tell and how to switch.

All the methods side by side

MethodCommand or pathNeeds sudoBest for
Current networknmcli device wifi show-passwordSometimesSharing it with someone, with a QR code
One saved networknmcli -s -g 802-11-wireless-security.psk connection show "Name"YesA network you are not near right now
All saved networksgrep -r '^psk=' /etc/NetworkManager/system-connections/YesMoving to a new laptop
Xfce / nm-connection-editorEdit Connections → Wi-Fi SecurityLogin passwordKali default desktop, no terminal
GNOME SettingsWi-Fi → gear → SecurityLogin passwordGNOME editions
iwd systems/var/lib/iwd/*.pskYesDistributions using iwd instead
wpa_supplicant only/etc/wpa_supplicant/wpa_supplicant.confYesMinimal installs, Raspberry Pi OS (older)

When the commands return an error instead of a password

The commands are short, and so are the ways they fail. Match the message you see to the fix:

What you seeWhyFix
Error: unknown connection 'Office 5G'The name does not match exactly, or has spaces without quotesCopy the name from nmcli connection show and wrap it in quotes
Blank output, no errorNo -s flag, no sudo, or the secret is kept in your desktop keyringAdd -s and sudo; if still blank, use the GUI method
Error: NetworkManager is not runningThe service is stopped, or the system uses iwd or wpa_supplicantsudo systemctl start NetworkManager, or read the iwd / wpa_supplicant files
Error: No Wi-Fi device foundNo adapter, or the driver is not loadedUse the connection or file method; fix the adapter separately
Permission denied on the filesThe folder is root-only by designPrefix the command with sudo
show-password is not recognizedA very old NetworkManager without that subcommandUpdate the system, or use the -s -g connection command

If the adapter itself has vanished, the no Wi-Fi adapter found guide covers the driver side. Your saved passwords are still in the files even while the adapter is missing, so the file method works regardless.

Work networks (WPA2-Enterprise) and hidden passwords

If the psk= line is missing, look at the [wifi-security] section's key-mgmt value. wpa-psk or sae (WPA3-Personal) means a shared password, and it will be there. wpa-eap means an enterprise network: there is no single Wi-Fi password, you sign in with your own username and password or a certificate, and those live in the [802-1x] section, often marked as stored by the desktop keyring rather than in the file. In that case the GUI method is the way to view them, and your workplace's IT team owns the credentials anyway.

A connection whose secret flags are set to "agent-owned" keeps the password in your GNOME Keyring or KDE Wallet instead of the system file. nmcli in a terminal will print nothing for it; the desktop's settings app, unlocked with your login, will show it.

If your Linux does not use NetworkManager

A few systems manage Wi-Fi another way. Check with systemctl is-active NetworkManager iwd wpa_supplicant.

  • iwd (some Arch and minimal setups): one file per network in /var/lib/iwd/, named after the SSID with a .psk extension. The Passphrase= line holds the password; some files store only a derived PreSharedKey=, which is not the original password.
  • wpa_supplicant directly: networks are listed in /etc/wpa_supplicant/wpa_supplicant.conf with psk="...". If the value is a long hex string without quotes, it is the derived key, not the password you typed.

The same job on Windows, Android and Mac

The keyword data shows most people asking this question also ask it for their other devices, so briefly:

  • Windows: netsh wlan show profile name="Office-5G" key=clear in Command Prompt; the password is the Key Content line. Or, on Windows 11, Settings → Network & internet → Wi-Fi → the network's properties → View Wi-Fi security key; for networks you are not connected to, Manage known networks → the network → Show beside the password.
  • Android 10 and later: Settings → Network & internet (or Connections) → Wi-Fi → tap the saved network → Share. After you confirm your screen lock, the password is shown under the QR code.
  • iPhone (iOS 16 and later): Settings → Wi-Fi → tap the ⓘ beside the network → tap Password and authenticate.
  • Mac: System Settings → Wi-Fi → the ··· next to a known network → Copy Password, or Keychain Access.

Keeping your saved Wi-Fi passwords safe

Because the passwords are plain text behind file permissions, the protections that matter are the ones around the machine:

  • Encrypt the disk. It is the only thing that stops someone with physical access booting another system and reading /etc.
  • Do not give sudo to people you would not give your Wi-Fi password to. On Linux, those are the same permission.
  • Forget networks you no longer use: nmcli connection delete "Old-Cafe". Fewer saved passwords, less exposure if the laptop is lost.
  • Scrub backups. Exclude /etc/NetworkManager/system-connections/ from backups you share or store in the cloud, or encrypt them.
  • Only look up passwords for networks you are entitled to. Showing a password your machine already has is ordinary administration. Using it to access a network you are not authorized to use is not, in most countries, legal.

Saved Wi-Fi passwords on Linux: the questions people ask

How do I see a saved Wi-Fi password in Kali Linux?

Run nmcli device wifi show-password for the network you are connected to. For any other saved network, list them with nmcli connection show and run sudo nmcli -s -g 802-11-wireless-security.psk connection show "Name". In the Xfce desktop, use Edit Connections, then the Wi-Fi Security tab, and check Show password.

Where are Wi-Fi passwords stored in Linux?

On systems using NetworkManager, in /etc/NetworkManager/system-connections/, one .nmconnection file per network. The password is on the psk= line in the [wifi-security] section. The files are readable only by root.

How do I view all saved Wi-Fi passwords on Linux?

Run sudo grep -r '^psk=' /etc/NetworkManager/system-connections/ to print every stored password with the file name of its network.

What is the command to show the Wi-Fi password in Linux?

nmcli device wifi show-password shows the current network's password and a QR code. sudo nmcli -s -g 802-11-wireless-security.psk connection show "Name" shows the password for a specific saved connection.

Are Wi-Fi passwords encrypted on Linux?

No. NetworkManager stores them in plain text and protects them with file permissions so only root can read them. Full-disk encryption is what protects them if someone gets physical access to the drive.

Why does nmcli not show my Wi-Fi password?

Run it with sudo, check the connection name is exactly right, and check the network type. Enterprise networks have no shared password, and connections whose secrets are stored in your desktop keyring show nothing in the terminal; use the desktop's network settings instead.

Can I see the Wi-Fi password without sudo?

For the network you are connected to, nmcli device wifi show-password may work without sudo depending on your system's permissions. Reading other saved networks or the stored files needs root. The desktop settings app asks for your login password instead.

How do I share my Wi-Fi with a QR code from Linux?

Run nmcli device wifi show-password; it prints a QR code in the terminal that a phone camera can scan to join the network. GNOME's Wi-Fi settings also offer a Share Network option that shows the same code.

Can I find the password for a Wi-Fi network I have never connected to?

No. These methods only show passwords your machine already stored after connecting successfully. They cannot recover or reveal the password for a network you have not joined.

How do I see saved Wi-Fi passwords on Android?

On Android 10 and later, open Wi-Fi settings, tap the saved network and tap Share. After you confirm your screen lock, the password appears under the QR code.

How do I see a saved Wi-Fi password on Windows?

Run netsh wlan show profile name="NetworkName" key=clear in Command Prompt and read the Key Content line. Recent Windows 11 builds also show it under the network's properties with View Wi-Fi security key.

Does this work on Ubuntu, Debian and Linux Mint too?

Yes. They use NetworkManager like Kali, so the nmcli commands, the file location and the GUI steps are the same. Only systems that use iwd or plain wpa_supplicant store passwords elsewhere.

How do I delete a saved Wi-Fi network in Kali?

Run nmcli connection delete "NetworkName", or open Edit Connections, select it and click the minus button. Its file in /etc/NetworkManager/system-connections/ is removed along with the stored password.

How do I move my saved Wi-Fi networks to a new Linux laptop?

Copy the .nmconnection files from /etc/NetworkManager/system-connections/ to the same folder on the new machine with sudo, keep them owned by root with permissions 600, and run sudo nmcli connection reload.

Where are Wi-Fi passwords stored in Raspberry Pi OS?

Current Raspberry Pi OS uses NetworkManager, so the same /etc/NetworkManager/system-connections/ folder applies. Older releases used /etc/wpa_supplicant/wpa_supplicant.conf.

Is it legal to view saved Wi-Fi passwords?

Viewing passwords your own device has stored for networks you are allowed to use is normal administration. Using a password to access a network without the owner's permission is illegal in most countries.

Ethan's client printed the password from that Tuesday and taped it inside the router cupboard, and changed it a week later to something they would remember. Jake now knows his laptop holds every Wi-Fi password it has ever been given, in a folder he can open, which made him turn on disk encryption when he reinstalled. Both outcomes came from the same small discovery. The password your machine already knows is yours to read; the job is keeping it from anyone else who gets the machine.

📌 If you keep one line from this page

nmcli device wifi show-password, and every saved one is in /etc/NetworkManager/system-connections/.

They are plain text behind sudo. Encrypt the disk if the laptop ever leaves the house.

Revision note. Written October 1, 2026, for Kali's current NetworkManager setup. If you are the one person in the office whose laptop still remembers the Wi-Fi, this page makes you the hero for a minute.

Related