Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Makosuke

macrumors 604
Original poster
Aug 15, 2001
6,748
1,437
The Cool Part of CA, USA
After upgrading my MBP to Sonoma, my Safari Toolbar has become un-editable. If I right-click and select "Customize Toolbar..." the icons jiggle like expected and I can move and delete them, but the page with the icons to add doesn't appear so I can't put things back that I deleted, and there's no way to accept the changes or leave edit mode other than quitting the app--all I can do is right-click again and select "Customize Toolbar..." a second time, at which point Safari immediately crashes.

I disabled all extensions, so that's not the reason, and my desktop with the same extensions installed is fine, so it's specific to this account.

What's bad though is that I can't even figure out where the toolbar preferences are now to delete them--I tried ~/Library/Preferences/com.Apple.Safari.plist but that did nothing (and hasn't been modified since 2020, so I assume it's no longer used). None of the other Safari prefs in the Preferences folder were relevant, so I tried moving the entire ~/Library/Safari/ folder but still have my screwed-up toolbar and the same issue.

I can, incidentally, switch to Compact Tabs view at which point editing works fine, but as soon as I switch back to the old-school view (which I prefer), same bug.

Anybody know where Safari stores its toolbar prefs now? (Or, alternately, have a suggestion for un-bugging what ails me?)
 

Diskutant

macrumors 6502
Jun 1, 2019
431
430
Preferences are cached, so just deleting the file and starting the app won't help. You need to restart the Mac. (maybe logout is enough, but I don't know)
And yeah the location of those files isn't that easy anymore. (Currently I'm not near a Mac so I can't check myself)
Besides the ones you checked look for ~/Library/Containers/
those are for Sandboxed Apps. There should be something like com.apple.safari
 

Makosuke

macrumors 604
Original poster
Aug 15, 2001
6,748
1,437
The Cool Part of CA, USA
Thank you! I was pretty sure that the newer sandboxing system was why I couldn't find the prefs, but couldn't come up with ~/Library/Containers/ for some reason.

Turns out that Preferences/com.apple.Safari.plist is actually the correct file, it just needs to be the one in the ~/Library/Containers/Safari/ container.

For what it's worth, caching was not an issue, and no reboots were required--just close Safari, move the .plist, and re-opening it was fine.

Conveniently, since plists are pretty human-readable, I was able to just delete all the keys that looked like they were related to the toolbar layout, and that fixed the issue (and reset the toolbar of course) without even having to delete all the rest of my prefs. Nothing looked corrupt there, but clearly something was hosed.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.