Google-chrome – Why does Chrome incognito keep cookies after the closing browser

google-chrome

Why does Chrome in incognito mode keep all cookies after closing the browser?

To reproduce this, do the following.

  1. Delete all your cookies and close the browser
  2. Open new incognito window (close "normal" window in case it is opened)
  3. Visit some website like twitter.com
  4. Close browser

Now I would expect all cookies to be deleted while I was browsing in incognito mode, but that is not what happens. Chrome keeps all cookies even if I have visited that website only in incognito mode.

5) Open Chrome, go to Settings -> Advanced settings -> Privacy (Content settings) -> All cookies and site data

And Twitter's cookies are still there although it shouldn't be.

If I set cookies settings to "Keep local data only until I quit my browser" Chrome deletes Cookies, but shouldn't Chrome delete cookies by default in incognito mode without me having to do that? After all, what is the point of incognito mode if it keeps all cookies?

Why is this happening?

Best Answer

As far as I know (and I have just run Incognito mode to verify this, although things may have changed since the question was posted), you cannot see what cookies Incognito mode is keeping - the ones you see in that dialog are ones you had prior to running Incognito mode.

Since the two are supposed to be separate, one mode will not delete the other mode's cookies even if you visit the same site, i.e., if you go to Twitter (or if there's a twitter widget on a page) in regular browsing you may pick up a Twitter cookie, but Incognito mode will not remove that if you launch it later and subsequently close it.

If you can still reproduce this issue, make sure you do not have any extensions that may be causing this cookie to be created, and that your start pages do not have any Twitter widgets on them.

(I had a similar issue where "Keep local data only until I quit my browser" did not work for me, because one of my extensions was keeping the browser open. Either disabling such extensions or "Continue running background applications when Google Chrome is closed" should fix that problem.)