I am currently working on a Sitecore 7.2 solution and the client asked us if we can change the expiration of the Global analytics cookie "SC_ANALYTICS_GLOBAL_COOKIE". We can see it is persisted for 10 years, which is odd because Sitecore documentation states it should be one year.
Apart from 10 years vs 1 year I went searching for answers but have not found any. I also went on a config/decompile mission but havent found the line yet where the cookie is saved.
So my main question is: is it possible to adjust the amount of time the global cookie is persisted?
Bonus kudos for anyone who can elaborate on the difference in documentation (1 year) vs reality (10 years) and why this seemingly insane amount of 10 years is used.
In case somebody comes looking for this about Sitecore 9+, you can now configure the expiry for the cookie via a patch file.
Analytics cookie lifetime
File:
c:\path\to\sitecore\root\App_Config\Sitecore\Marketing.Tracking\Sitecore.Analytics.Tracking.configDetermines the lifetime of the tracking cookie (
SC_ANALYTICS_GLOBAL_COOKIE) in hours. The default value is 87600 hours (10 years).
<setting name="Analytics.CookieLifetime" value="87600" />
From documentation: https://doc.sitecore.net/developers/xp/tracking-and-session/tracker/configuration.html#analytics-cookie-lifetime
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With