I have a multisite configuration running SC8.2u2. All sites have a common domain name xxx.com, however the SC_ANALYTICS_GLOBAL_COOKIE domain name on sub-sites is set to the sub-domain accounts.xxx.com and legal.xxx.com so the global cookie does not match for users when they traverse to a different sub-site.

How is the domain name set for a given sub-site and is there a way to control it? And can I force all sites to use a common wildcard .xxx.com?

2 Answers
2

You'll want to set a <httpCookies> configuration in your Web.config that allows for a wildcard domain. This is done by specifying the root of your domain in the cookie.

Note: that by changing this cookie, this will require people to log back into Sitecore and may need cookies to be cleared in order to take effect. Test heavily to ensure it works for all of your use cases.

Add more details to your answer like description why this solves the problem and why answer from February that was already accepted is not good from your point of view. Otherwise please delete this answer and make it as a comment
– Peter ProcházkaJul 12 '18 at 6:37

this solution will add cookie domain ONLY for the "SC_ANALYTICS_GLOBAL_COOKIE" cookie for all your domain and sub domains! where as adding the httpcookie domain value at the web.config will get affect or it forces all your cookies to point to the main domain.
– Iam007EshwarJul 12 '18 at 9:35