How to view your Wi-Fi password on MacOS: all the methods from Keychain Access to Terminal

Forgot your home or office Wi-Fi password, but your MacBook or iMac automatically connects to the network? This situation is familiar to many: the router has been configured for a long time, the sticker with the password has been lost, and you need to grant access to guests or a new device. Luckily, macOS stores all saved network passwords. in a secure storage and can be retrieved without resetting the router.

In this article you will find 5 working methodsHow to view your Wi-Fi password MacOS — from the standard Keychain interface to commands in TerminalThe methods have been tested on the latest versions of the system (Sonoma 14.x, Ventura 13.x, Monterey 12.x) and fit all models Mac (including MacBook Air/Pro on M1/M2/M3 And Intel). We'll also discuss what to do if your password isn't displayed or the system requests administrator rights.

⚠️ Important: All methods require that your Mac Connected to the network you're looking for at least once. If the network isn't listed, you'll have to reset the password on the router.

📊 How often do you forget your Wi-Fi passwords?
Often, you have to search every time
Sometimes, if I don't connect new devices for a long time
There is always a sticker with the password nearby.
I never forget

1. Method: Via Keychain Access - the easiest method

Keychain is a built-in password storage in macOS, where data from Wi-Fi, websites, apps, and even bank cards is stored. To find the network password:

  1. Open Spotlight (combination ⌘ + Space) and enter Bunch of keys (or Keychain Access (on the English keyboard layout). Press Enter.
  2. Select a category in the left column System (or System).
  3. In the search bar (upper right corner) enter the name of your Wi-Fi network.
  4. Double-click on the found network in the list.
  5. Check the box next to Show password (Show password).
  6. The system will ask administrator password - enter it and press Allow.

Done! The password will be displayed in the field. Show password. It can be copied (⌘ + C) or write down.

Is the "Show password" box missing? → Make sure the correct partition is selected ("System")

Is the system asking for an administrator password? → Enter the one you use to log in to your Mac

Network not found? → Perhaps your Mac never connected to it or the password wasn't saved.

⚠️ Attention: if you use guest account on Mac or login by Touch ID Without a password, this method will not work. In such cases, you will need administrator access or alternative methods.

Method 2: Via Terminal – for advanced users

If you prefer to work with the command line, you can extract the Wi-Fi password using TerminalThis method is faster, but requires precise command entry. Here are the step-by-step instructions:

  1. Open Terminal (through Spotlight or folder Utilities V Programs).
  2. Enter the command to search for all saved networks:
    security find-generic-password -wa "Your_Network_Name"

    Replace Your_network_name to the actual Wi-Fi name (case sensitive!).

  3. The system will ask administrator password - enter it and press Enter.

After that in Terminal The password will be displayed in the following format:

password: "your_wifi_password"

🔹 Example: if the network is called MyHomeWiFi_5G, the command will be:

security find-generic-password -wa "MyHomeWiFi_5G"

⚠️ Attention: if you use macOS Monterey 12.0–12.3, in this version there was Error displaying passwords through the TerminalUpdate your system to the latest version or use Keychain.

3. Method: via router settings (if you have access)

If the previous methods didn't work (for example, the network isn't saved in Keychain), you can view the password directly in router web interfaceTo do this:

  1. Find out Router IP address:
    • 🔌 Open System Preferences → Network → Wi-Fi → Advanced → TCP/IP.
    • Look at the line Router - this is the IP (usually 192.168.0.1 or 192.168.1.1).
  • Open your browser and enter this IP into the address bar.
  • Enter login and password for the router (usually admin/admin or indicated on the device sticker).
  • Go to the section Wireless (or Wi-Fi, Wireless network) and find the field Password/Password.
  • 📌 A table with standard login details for popular router brands:

    Manufacturer IP address Login Password
    TP-Link 192.168.0.1 or 192.168.1.1 admin admin
    ASUS 192.168.1.1 admin admin
    Xiaomi 192.168.31.1 admin Indicated on the sticker
    Keenetic 192.168.1.1 admin Indicated on the sticker

    ⚠️ Attention: If you haven't changed the default login details for your router, update them first in the section System Tools → Password (or similar). This will protect your network from hacking.

    4. Method: via iCloud Keychain (if synchronization is enabled)

    If on yours Mac Password synchronization is enabled via iCloud Keychain, you can try to find the Wi-Fi password on another device Apple (For example, iPhone or iPad). To do this:

    1. On iPhone or iPad open Settings → Wi-Fi.
    2. Find your network in the list and tap on the icon ! (information).
    3. Click Copy password (if the option is active).
    4. Insert password on Mac (⌘ + V).
    5. 🔹 Conditions:

      • 📱 Both devices must have one Apple ID.
      • ☁️ Synchronization enabled iCloud Keychain (Settings → [Your name] → iCloud → Passwords & Keys).
      • 🔒 Devices must be unlocked (does not work in blocking mode).

      What should I do if the "Copy password" option is inactive?

      This means your password isn't syncing via iCloud. Try this:

      1. Enable iCloud Keychain on both devices (Mac and iPhone).

      2. Connect to the network on iPhone manually (enter the password again).

      3. Restart your devices and check synchronization after 5-10 minutes.

      Method 5: Using third-party utilities (if nothing else helps)

      If standard methods don't work, you can use specialized programs for extracting passwords. They are suitable for advanced users and often require administrator rights.

      🔧 Popular utilities:

      • 🖥️ WiFi Password Revealer — a free program with a simple interface.
      • 🔓 Keychain Access Explorer — Advanced Keychain viewer.
      • 🛠️ MacPass — an open password manager (similar to KeePass for macOS).

    ⚠️ Attention: download programs only from official websites (For example, Mac App Store or verified sources like GitHub). Utilities from unverified sources may contain malicious code.

    📌 Example of working with WiFi Password Revealer:

    1. Download and install the program.
    2. Run it (you will need to enter the administrator password).
    3. Find your network in the list and copy the password.

    Common problems and solutions

    Sometimes users encounter errors when trying to view their password. Here common situations and ways to solve them:

    🔴 Problem 1: Keychain does not show the password after entering the administrator password.

    • 🔄 Reboot Mac and try again.
    • 🛠️ Check if Keychain Access is disabled in System Preferences → Touch ID & Passcode.
    • 🔑 Try resetting the administrator password via Password reset utility (booted into Recovery Mode).

    🔴 Problem 2: The terminal gives an error Could not find password item.

    • 🔍 Make sure the network name is entered no typos (case sensitive!).
    • 📡 Check that Mac connected to this network at least once.
    • 🔄 Try the command security dump-keychain -d login.keychain | grep "airport" to search all networks.

    🔴 Problem 3: I can't log into the router.

    • 🔌 Check that Mac connected to the router via cable or Wi-Fi.
    • 🔄 Reset the router using the button Reset (hold for 10 seconds) if you forgot your login details.
    • 📞 Contact your ISP—some operators block access to router settings.

    FAQ: Answers to frequently asked questions

    Is it possible to find out the password for a Wi-Fi network that a Mac has never connected to?

    No. MacOS Stores passwords only for networks the device has connected to at least once. If the network isn't in Keychain, you'll need to:

    • View the password on another device that has connected to this network.
    • Reset your router and set it up again.
    • Contact the network owner (e.g. office administrator).
    Is it safe to use Terminal to extract passwords?

    Yes, as long as you enter commands accurately and don't run suspicious scripts. Commands like security find-generic-password - This built-in macOS features, they do not harm the system. However:

    • Do not copy commands from unverified sources.
    • Do not enter administrator passwords on other people's websites.
    Why isn't my network listed in Keychain Access?

    Possible reasons:

    • 📡 Mac connected to the network, but the password was not saved (the “Remember network” box was unchecked).
    • 🗑️ The network entry was manually deleted.
    • 🔄 The network was renamed on the router (the old name remains in the Keychain, but it is no longer relevant).

    Solution: Connect to the network again and make sure that the "Remember this network" box is checked when connecting.

    Is it possible to export all Wi-Fi passwords to a file?

    Yes, for this:

    1. Open Terminal.
    2. Enter the command:
      security dump-keychain -d login.keychain | grep "airport" | awk '{print $2}' | xargs -I {} security find-generic-password -ga {} | grep "password:"
    3. Copy the output to a text file.

    ⚠️ Attention: Store the password file in a safe place (for example, in an encrypted archive).

    Do these methods work on macOS Sonoma?

    Yes, all the methods described are relevant for macOS Sonoma 14.x, including:

    • "Keychain" (the interface has not changed).
    • Teams in Terminal.
    • Access to the router via a browser.

    Exception: in Sonoma further confirmation may be required through Touch ID when prompted for an administrator password.