Forgot your home or office Wi-Fi password, but your MacBook Connected to the network? Don't rush to reset your router or ask your neighbors for the password. macOS There are several built-in ways to retrieve a saved password, from simply viewing it in Keychain Access to commands in TerminalIn this article we will look at all the current methods for macOS Sonoma and earlier versions, including workarounds if the default settings don't work.
It is important to understand: the password can only be seen for those networks to which MacBook previously connected. If the network is new or the data has been erased (for example, after a system reinstallation), alternative access will be required—through the router settings or a device that is already connected. Also keep in mind that some corporate networks (with WPA2-Enterprise) may block viewing of the password due to security policy.
Before you begin, please check:
- 🔹 Yours MacBook is currently connected to the target Wi-Fi network (or was connected previously).
- 🔹 You have administrator rights on this device (to access Keychain).
- 🔹 The "Hide SSID" mode is not enabled on the router; otherwise, the network may not appear in the list of saved networks.
1. View your password via Keychain Access (the easiest way)
"Keychain" (Keychain Access) is a built-in password manager in macOS, where all saved login data is stored, including Wi-Fi network passwords. This method works on all versions of the system, starting with OS X Lion, and does not require technical skills.
To find your password:
- Open the app
Bunch of keys(can be found viaSpotlighton request "Keychain"). - Select a category in the left column
System(orLocal elements, if the network is not in the system link). - In the search bar, enter the name of your Wi-Fi network (
SSID). - Double-click on the found entry and check the box.
Show password. - Enter your account password MacBook (requires administrator rights).
If the password is not displayed or the field is empty, check:
- 🔄 It is possible that the network is saved in a different bundle (for example,
iCloud). Try to chooseAll elementsin the left column. - 🔐 If you see the message "Access Denied," it means your account does not have administrator rights.
- 📡 The network may have been removed from the connection after a factory reset or system update.
Check all categories of connections (System, Local Items, iCloud)
Make sure you're looking for the exact network name (case is important!)
Try searching for the network by searching for "airport" (older versions of macOS)
Please restart your MacBook and try again-->
2. Using Terminal to extract the password
If the Keychain GUI does not show the password (for example, due to an access error), you can extract it via Terminal using the command securityThis method is suitable for experienced users and requires precise command entry.
Step-by-step instructions:
- Open
Terminal(throughSpotlightor folderUtilities). - Enter the command to search for all saved Wi-Fi networks:
security find-generic-password -wa "NETWORK_NAME"Replace
NETWORK_NAMEonSSIDyour network (for example,security find-generic-password -wa "my_wifi_5G"). - Click
Enterand enter the password for your account MacBookwhen the system asks.
If the command returns an error Could not find any matching items, try an alternative option:
security find-generic-password -D "AirPort network password" -a
This command will list all saved Wi-Fi networks. Find the one you need and copy its exact name (including spaces and case), then repeat step one.
3. Viewing the password through the router settings
If MacBook If you haven't saved the password (for example, after a system reset), but you have access to the router, you can find the password through the device's web interface. This method is universal and works regardless of the model. MacBook or versions macOS.
Instructions:
- Find out
IP addressyour router. Usually it's192.168.0.1or192.168.1.1You can check it inTerminalcommand:netstat -nr | grep default - Open your browser and enter the IP address in the address bar. Click
Enter. - Enter your login and password to enter the router settings (usually this is
admin/adminor indicated on the device sticker). - Go to the section
Wi-Fi(orWireless network,Wireless) and find the fieldPassword(Password,Key).
⚠️ Attention: If you haven't changed your router's default login details, you can find them on the device's sticker or in the manual. However, this isn't secure—after viewing the password, we recommend changing your administrator login and password to something more secure.
| Router model | Standard IP address | Default login/password |
|---|---|---|
| TP-Link (Archer, Deco) | 192.168.0.1 or 192.168.1.1 |
admin/admin |
| ASUS (RT-AX, ZenWiFi) | 192.168.1.1 |
admin/admin |
| Keenetic | 192.168.1.1 |
admin/1234 (or indicated on the box) |
| Xiaomi (Mi Router) | 192.168.31.1 |
The password is the same as the Wi-Fi network password. |
If you can't access your router settings, it's possible the IP address or administrator password has been changed. In this case, the only option left is to reset the router to factory settings (using the button). Reset on the back panel), but this will delete all current settings, including the Wi-Fi password.
4. Alternative methods (if nothing works)
If the standard methods don't work, try one of these options:
- 📱 View password on another device: If connected to the same network iPhone, iPad or Windows PC, you can extract the password from there. For example, on iPhone With iOS 16+ The password can be copied to the clipboard via
Settings → Wi-Fi → ⓘ next to the network → Password. - 🖥️ Restoring from a backup: If you have a backup MacBook V Time Machine, you can restore Keychain from a backup. To do this, open
Bunch of keys, select from the menuFile → Restore Keychain from Time Machine Backup. - 🔧 Using third-party utilities: Programs like WiFi Password Revealer or Keychain Access Explorer may help if system tools don't work. However, be careful - download software only from official sources (for example, Mac App Store).
⚠️ Attention: Third-party password extraction utilities may request access to sensitive data. Before installing, check reviews and the developer's reputation. Some programs may contain malicious code disguised as legitimate software.
What should I do if the network doesn't appear in Keychain?
If a Wi-Fi network does not appear in the list of saved networks, this may mean:
1. The network was connected in guest mode (without saving the password).
2. The data has been deleted after updating macOS or resetting settings.
3. The network uses Enterprise authentication. (for example, in offices or universities), and the password is stored not locally, but on the authentication server.
4. The MacBook was connected via a USB/ETH adapter, and the network is saved in another bundle.
In such cases, the only option left is to reset the password on the router or request it from the network administrator.
5. Common mistakes and how to avoid them
When trying to view the Wi-Fi password on MacBook Users often encounter typical problems. Let's look at the most common ones and how to solve them:
- 🔴 Access Denied Error: This occurs if your account doesn't have administrator rights. Solution: Log in with an account that does.
adminor request access from the device owner. - 🔴 Network not found in Keychain: Make sure you're searching for the exact network name (including case and spaces). If the network was connected a while ago, try searching for the word
airport(old name of the Wi-Fi module in macOS). - 🔴 The terminal does not return the password: Make sure you entered the network name correctly. If the name contains spaces or special characters (e.g.,
My_Wi-Fi_2.4G), put it in quotation marks. - 🔴 The router does not open the web interface: Make sure you're connected to the router's network (via Wi-Fi or cable). If the IP address has changed, find it via
Terminalteamarp -a.
If you're using macOS Ventura or later, some Terminal commands may require explicit confirmation of Keychain access. In this case, after entering the command, a system prompt will appear asking for your password—this is normal.
6. Security: How to protect your Wi-Fi password
Once you know your Wi-Fi password, it's worth considering its security. If the password is simple (for example, 12345678 or qwerty), it's easy to hack. Here are some recommendations:
- 🔒 Use complex passwords: The minimum length is 12 characters, with a combination of letters (upper and lower case), numbers, and special characters. Example:
kL9#pR2@xQ1!mN. - 🔄 Update your password regularly: Change it every 3-6 months, especially if guests or temporary users have connected to the network.
- 📡 Disable WPS: Function
Wi-Fi Protected SetupVulnerable to brute-force attacks. Disable it in your router settings. - 👥 Create a guest network: For friends or temporary devices, set up a separate network with limited access to local resources.
If you suspect your Wi-Fi has been hacked (for example, your internet speed has slowed down or unknown devices have appeared in the list of connected devices), change your password immediately and check your router for malware. Some viruses can spoof DNS servers or redirect traffic.
FAQ: Answers to Frequently Asked Questions
Is it possible to find out the password for a Wi-Fi network that my MacBook has never connected to?
No. MacBook Stores passwords only for networks it has previously connected to. If the network is new, the only options are to request the password from the network owner or reset the router (if you have physical access to it).
Why isn't my Wi-Fi network listed in Keychain?
Possible reasons:
- The network was connected in guest mode (without saving the password).
- The data was deleted after updating macOS or resetting the settings.
- You are looking for the wrong network name (check case and spaces).
- The network uses Enterprise authentication (the password is stored on the server, not locally).
Try searching by word airport or check other connections (eg iCloud).
Is it possible to find out the Wi-Fi password on a MacBook without administrator rights?
No. To view passwords in Keychain or through Terminal Administrator rights are required. If you don't have access, ask the owner. MacBook Enter your password or grant access to your account.
Do these methods work on macOS Sonoma?
Yes, all the methods described (via Keychain, Terminal and router settings) work on macOS Sonoma and earlier versions, starting with OS X LionHowever, newer versions of macOS may require additional confirmation to access sensitive data.
How to reset a Wi-Fi password if it cannot be recovered?
If none of these methods work, you can reset your router to factory settings:
- Find the button on the back of the router.
Reset(usually recessed into the body). - Press and hold it for 10-15 seconds (until the indicators flash).
- The router will reboot and you will be able to access the settings using the default IP address (for example,
192.168.1.1) with default login/password.
⚠️ Attention: A reset will erase all settings, including the network name, password, associated devices, and firewall rules. After the reset, you will need to reconfigure the router.