By default, the tracking cookie is saved on the current domain where the click script is implemented.
If your user flow spans multiple subdomains (e.g. landing page β checkout), you need to store the cookie on the parent domain to ensure tracking works correctly across all subdomains.
When should you use this?
Use this setup if:
Your landing page and conversion page are on different subdomains
You want to track users across multiple subdomains
Example:
Landing page:
promo.yourwebsite.comCheckout:
checkout.yourwebsite.com
Step 1: Update the click script
Add the cidDomain parameter to your click script:
<!-- Trackdesk tracker begin -->
<script async src="//cdn.trackdesk.com/tracking.js"></script>
<script>
(function(t,d,k){(t[k]=t[k]||[]).push(d);t[d]=t[d]||t[k].f||function(){(t[d].q=t[d].q||[]).push(arguments)}})(window,"trackdesk","TrackdeskObject");
trackdesk("yourtenantid", "click", { _meta: { cidDomain: '.yourparentdomain' } });
</script>
<!-- Trackdesk tracker end -->
What to update:
Replace
yourtenantidwith your actual Tenant IDReplace
.yourparentdomainwith your root domain
Example:
Use
.yourwebsite.comfor all subdomains ofyourwebsite.com
Step 2: Update the conversion script
You must apply the same configuration when creating conversions:
<!-- Trackdesk tracker begin -->
<script async src="//cdn.trackdesk.com/tracking.js"></script>
<script>
(function(t,d,k){(t[k]=t[k]||[]).push(d);t[d]=t[d]||t[k].f||function(){(t[d].q=t[d].q||[]).push(arguments)}})(window,"trackdesk","TrackdeskObject");
trackdesk("yourtenantid", "conversion", {
_meta: { cidDomain: '.yourparentdomain' },
"conversionType": "lead"
});
</script>
<!-- Trackdesk tracker end -->
β οΈ Important
The same
cidDomainvalue must be used in both scriptsThe value must include a leading dot (e.g.
.yourdomain.com)If not configured correctly, conversions across subdomains may not be tracked
How it works
The cookie is stored on the parent domain
It becomes accessible across:
All subdomains
The root domain
The cookie name follows this format:
β trakdesk_cid_{tenantId}
Summary
Default behavior stores cookies per domain
Use
cidDomainto enable cross-subdomain trackingThis ensures conversions are correctly attributed across your entire domain structure
