Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

Delete Safari cookies so they stay deleted Web Browsers
This is a very simple hint, but I haven't found the information anywhere else.

When you delete cookies in Safari 4, whether from within its Preferences dialog or in some other way, they will all mysteriously reappear anywhere from a few minutes to perhaps an hour later. I've seen several accounts of why this happens and how to prevent it, but none of them worked for me.

What did work is this: after deleting the cookies, quit Safari immediately, before it has time to restore them. When you relaunch Safari, the cookies will be gone for good. Apparently they're being cached in memory and written back to the Cookies.plist file periodically.
    •    
  • Currently 3.11 / 5
  You rated: 1 / 5 (27 votes cast)
 
[32,294 views]  

Delete Safari cookies so they stay deleted | 11 comments | Create New Account
Click here to return to the 'Delete Safari cookies so they stay deleted' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Delete Safari cookies so they stay deleted
Authored by: freaktheclown on Oct 19, '09 10:08:51AM

I find that this happens with Google a lot. Often when I click Sign Out at google.com, the page will reload but I will still be logged in. Even after I delete every Google cookie in preferences and refresh - I am still logged in sometimes. Don't know whether it's this or a Google problem but I hope this helps next time it happens.



[ # ]
Delete Safari cookies so they stay deleted
Authored by: tedw on Oct 19, '09 11:00:55AM

That is odd behavior, and I can't imagine that it in intentional. You ought to report it to Apple as a bug.



[ # ]
Delete Safari cookies so they stay deleted
Authored by: william pope on Oct 30, '09 04:40:20PM

if you don't use Safari 4.0 you don't understand the problem



[ # ]
Delete Safari cookies so they stay deleted
Authored by: sarwargs on Oct 19, '09 11:17:50AM

This is really a wonderful hint, and it works. I read a recent article about this issue at http://www.macworld.com/article/143343/2009/10/safaricookieproblems.html
and it is a real problem with safari 4.



[ # ]
Delete Safari cookies so they stay deleted
Authored by: tice on Oct 19, '09 02:15:08PM
Since Apple seem not to care much abou user privacy in case of cookies the best way now again is the freeware Safari Cookies: http://sweetpproductions.com/safaricookies/index.htm

To use it install the also free 64-bit SIMBL http://www.culater.net/software/SIMBL/SIMBL.php an from now on you can set favorites in cookies and delete (or automatically delete) all non-favorites easily. Works fine now in Snow Leopard.

[ # ]
Delete Safari cookies so they stay deleted
Authored by: lincd0 on Oct 19, '09 03:21:18PM

Safari Cookies is just another way to delete items from the Cookies.plist file. They'll still reappear if you don't quit Safari after deleting them.

This is getting beyond the scope of the discussion, but SIMBL has a big security hole and shouldn't be used by anyone who doesn't understand the risk, which is to say probably everyone who uses it.



[ # ]
Delete Safari cookies so they stay deleted
Authored by: David Allen on Oct 19, '09 02:18:23PM

There is hint, I believe that it is here at Mac OS X Hints, that shows you how to create session only cookies. So when you finish a session with Safari, no matter a few hours, a day, a week, when you Quit Safari, all the cookies that you picked up during that session are discarded, never to return.

It is done by changing the permissions on ~/Library/Cookies to Read Only.

Now there are cookies that you want to keep because they make life easier, such as for your secure bank website, websites you visit often for which you have an account, etc. So one day after a full day of surfing and purposely visiting every site important to me, I went to Safari/Preferences/Security and edited the cookies, only retaining the ones I wanted. Next I quit Safari and went to ~/Library/Cookies and left-clicked to Get Info. I changed the permissions to Read Only for me and No Access for everyone else.

---
Dah•veed |David Allen|
Monterrey, NL, Mexico



[ # ]
Delete Safari cookies so they stay deleted
Authored by: RedFred on Oct 19, '09 02:24:39PM

One thing most people don't realize is that cookies (the Cookies.plist file) are shared amongst all applications that use the NSURL class. This means that other applications can write a cookie and Safari will see it when it starts up. This is the reason the google.com/PREF cookie keeps reappearing after deletion even if you have your Safari preference set to never accept cookies. This cookie gets set by a helper program that maintains the Safebrowsing database. Also, as has been pointed out, Safari keeps an internal copy of cookies which it periodically syncs back out to the Cookies.plist in your library. One side affect of this is that if you delete the Cookies.plist while Safari is open, when Safari next syncs it internal copy back to the cookie file, cookies you thought were deleted reappear.

One other technical problem is that Safari doesn't use the built in API's to post a notice in the NSHTTPCookieStorage class when it changes cookies so other programs can be aware of them.

Cookie management and handling is one of Safari's biggest weaknesses as far as I'm concerned.



[ # ]
Delete Safari cookies so they stay deleted
Authored by: everkleer80 on Oct 19, '09 02:39:14PM

Heh, I never even thought about whether something like this might be an issue or not... I've always just instinctually restarted my browser without thinking about it. Good to know it's SUPPOSED to work lol!



[ # ]
Delete Safari cookies so they stay deleted
Authored by: Philscbx on Oct 20, '09 10:03:00AM

Interesting,
Silly Plists & Permissions. Always something.
I hope some 3rd party just takes over the whole process, hunts down any fixes any issue on the fly. Sorta like Norton used to do back when we wrote notes on rocks.

You'd think a group of Guru's, like Google & Apple do it.
Brain storm perfection software. Leaving nothing to fix.
Oh alright then, I guess I have to do everything. Time left is short.

Unreal, another Mac site.
What ever it takes to keep this MacPro up to speed, Ok.



[ # ]
Delete Safari cookies so they stay deleted
Authored by: william pope on Oct 30, '09 04:38:15PM

The best way to delete those DAMN COOKIES is to boycott all Mac products until MACINTOSH posts (and keeps posting) THEIR RECOMMENDED METHOD for those using Safari 4.0.

They created this PUBLIC NUISANCE and are dramatically profiting from it.

The Other Pope



[ # ]