Where apps hide your files
The Mac keeps its list of known Wi-Fi networks in a root-only plist under /Library/Preferences, and the passwords in a keychain. Here are the files, the safe way to list or forget a network, and what not to copy.
On macOS 15 Sequoia, the list of Wi-Fi networks your Mac has joined is in this file:
/Library/Preferences/com.apple.wifi.known-networks.plist
On the Mac used for this guide it is about 150 KB, owned by root, and readable by root only (permissions -rw-------). That is deliberate: it holds the names and join details of networks from places you have been. You cannot open it as a normal user, and you should not try to work around that. The passwords themselves are keychain items, covered below.
Check that it exists, without reading it:
ls -lO /Library/Preferences/com.apple.wifi.known-networks.plist
To open the folder in Finder, choose Go > Go to Folder (⇧⌘G), type /Library/Preferences and press Return. Only Sequoia was checked for this guide, so on Sonoma or Tahoe confirm the name with ls /Library/Preferences | grep -i wifi, which lists names and reads nothing.
| File | What it is |
|---|---|
/Library/Preferences/SystemConfiguration/com.apple.airport.preferences.plist | Older guides name this as the saved-networks file. On the Mac used for this guide it is under 2 KB and readable by everyone, so it is not the network list on Sequoia |
/Library/Preferences/SystemConfiguration/preferences.plist | The Mac's network configuration: services, their order and their settings. Around 11 KB here. It controls DNS, proxies and every other interface, not only Wi-Fi |
/Library/Preferences/SystemConfiguration/NetworkInterfaces.plist | The list of network hardware macOS has seen |
/Library/Preferences/com.apple.airport.opproam.plist | A very small Wi-Fi roaming file, a few hundred bytes here |
None of these is meant for hand editing, and preferences.plist holds far more than Wi-Fi, so leave it alone.
A Wi-Fi password is stored as a keychain item of the kind AirPort network password. Those for networks the Mac joins are normally in the System keychain, the file /Library/Keychains/System.keychain. If iCloud Keychain is on, networks you joined can also sync between your Apple devices; the Wi-Fi settings on Sequoia say so in the warning shown when you forget a network: "Your Mac and other devices using iCloud Keychain will no longer join this Wi-Fi network."
To read one password you are entitled to know, use Keychain Access, not the file. On Sequoia the app is no longer in the Utilities folder; it is at /System/Library/CoreServices/Applications/Keychain Access.app, so open it from that path or by searching for it. Search for the network name, double-click the AirPort network password item and tick Show password. It asks you to authenticate first (an administrator name and password for an item in the System keychain). Read it on screen and leave it there.
Never copy System.keychain or the known-networks plist to share or to "back up" in a cloud folder. They are private data, and a copy outside the protected folder loses the protection.
The Wi-Fi interface is en0 on most Macs. Confirm it, then list the names:
networksetup -listallhardwareports
networksetup -listpreferredwirelessnetworks en0
The second command prints only network names, one per line, and changes nothing. A long list of café and hotel names says where you have been, so do not paste it into a forum or a support chat. The same list appears in System Settings: open Wi-Fi, scroll down and click Advanced, and the networks are under Known Networks (the Sequoia layout in Apple's guide).
The supported way is the Wi-Fi settings pane. Apple's steps:
Apple says this forgets the network and its password. For the network you are on right now, Details then Forget This Network… does the same. If you only want the Mac to stop joining a network automatically, turn off Auto-Join in that menu instead and keep the password. With iCloud Keychain on, forgetting a network on this Mac makes your other Apple devices forget it too.
There is a command-line equivalent that does change things. It removes the named network from the list, so run it only when you mean it:
sudo networksetup -removepreferredwirelessnetwork en0 "Network Name"
Use quotes for names with spaces. Forgetting a network removes it from the list, and you may need the password to join it again, so make sure you know it before you forget a network you still need.
Order matters. Turn Wi-Fi off and on, restart the Mac and the router, then forget and rejoin the one network that misbehaves. Apple's own Wireless Diagnostics app, at /System/Library/CoreServices/Applications/Wireless Diagnostics.app, is the supported next step for looking deeper.
Some community guides go further and move network configuration files out of /Library/Preferences/SystemConfiguration so that macOS rebuilds them. Apple does not document that routine for current releases, and it resets every network setting (static addresses, VPNs, proxies, custom DNS), not only Wi-Fi. If you ever do it, it needs an administrator password, the files must be copied to a backup folder first so they can be put back, and it belongs at the very end of the list.
Known networks are tied to the Mac and to iCloud Keychain, not to a file you can carry. Signing in to the same Apple Account with iCloud Keychain on is the route Apple's Wi-Fi settings describe for sharing networks between devices. Copying the plist or the keychain by hand is not a supported route.
/Library/Preferences is outside your home folder and not part of Finder's normal search scope. The plist names have no obvious relation to the words "Wi-Fi network" either, and the files you can read are not the ones that hold your list.
Typing known-networks or airport.preferences into Everywhere shows each file with its path and its size, which is enough to tell which is which and whether the old-style file still exists. It matches names only and cannot read the plist, which is the safe outcome here. /Library/Preferences is a system folder, so it is covered without Full Disk Access, though a file made a few minutes ago can wait for the next scan.
On macOS 15 the list is in /Library/Preferences/com.apple.wifi.known-networks.plist, a root-only file. Older guides point to com.apple.airport.preferences.plist in /Library/Preferences/SystemConfiguration, which is a small, world-readable file on Sequoia and not the list.
In a keychain, as AirPort network password items, normally in the System keychain at /Library/Keychains/System.keychain. To view one, open Keychain Access, double-click the item and tick Show password, which asks you to authenticate.
Open System Settings > Wi-Fi, click Advanced, click the More button next to the network under Known Networks, choose Remove From List and confirm with Forget. With iCloud Keychain on, your other Apple devices forget it too.
Yes. Run networksetup -listpreferredwirelessnetworks en0 in Terminal, or open System Settings > Wi-Fi > Advanced and look under Known Networks. Both show names only.
Everywhere keeps track of every file on your Mac — including the folders Spotlight hides and drives you have unplugged. Free for a day, then $19 once.
Version 2.20.3 · macOS 13+ · 4.7 MB · notarised