Delete Wi-Fi network from mac
How do I delete a network from my Mac?
I removed it from network preferences in the advanced pane but it still appears connected in my list.
I also tried looking for it in Keychain Access but it's not there and I'm still connected.
-
Disconnect from your current network:
sudo /System/Library/PrivateFrameworks/Apple80211.framework/V*/A/R*/airport -z
-
Go to System Preferences → Network → Wi-Fi → Advanced… and remove the network from the list of preferred networks.
I have recently asked a very similar question and got much better answer in comments. Sorry for the duplicate, but I was using completely different keywords to describe the issue, so didn't find this one before.
Have a look at Andrew's answer here link to the topic
I would recommend using your MacBook (disabling WiFi and removing it from a wired connection of you have one) then remove the networks from System Preferences and Keychain Access.app . Go to your iPhone and turn off iCloud Keychain. Restart your phone and put your MacBook back on the network/internet and let it sync. After a few minutes (5-10) you should be able to turn on your iPhone's iCloud keychain.
The fact that the network can't be successfully eliminated doesn't appear to have any connection to iCloud, as it happens on my MacBook which is not connected to iCloud.
What's happening is that the WIFI network password is being stored in Keychain Access. Until it is eliminated from there the Mac will keep on connecting even though it has been instructed to forget a WIFI network. I even wiped the WHOLE content of the Library/Preferences folder and it still remembered the network, so that gave me the clue to check Keychain Access. As soon as I removed the netowrk from Keychain Access, and restarted, I got the "none of your preferred networks are available" dialog