Cross-domain tracking for checkout and booking pages
Short answer
Cross-domain tracking keeps a visitor's identity and ad source intact when they move between domains, such as your site, a hosted booking page and a payment checkout. Cookies cannot cross domains, so you hand the identity over at each hop using URL parameters, analytics linker settings, hidden fields or a reference ID passed to the payment provider.
Your ad sends people to your site, but the booking or payment happens somewhere else: a scheduling tool's hosted page, a payment provider's checkout, a separate shop domain. At each of those jumps the visitor arrives as a stranger, and the conversion gets credited to the previous domain instead of your ad. This guide shows how to map each hop in your funnel and pick the right handoff for it.
Why identity breaks between domains
Browsers keep cookies separate per site. The visitor ID your analytics stored on yoursite.com cannot be read by bookingtool.com, even if the same person is clicking through in the same tab. The UTMs and click ID in the original landing URL are also gone by the second page unless something carried them forward.
Two symptoms show up in reports:
- Self-referrals and vendor referrals. Analytics reports conversions as coming from your booking vendor's domain or
checkout.stripe.com, because that was the last site the visitor came from before landing on your thank-you page. - Orphan conversions. The booking tool records a booking, your CRM records a contact, and neither has any campaign information.
Neither is a platform bug. Each hop needs an explicit handoff.
Map every hop first
Before changing settings, draw the actual path. Take a solar panel cleaning service in Denver. Their funnel looks like this:
- A Meta or Google ad lands on
sunrinse.com/residential(their site). - "Get a price" opens a quote and scheduling page hosted by their field-service software on the vendor's domain.
- A $40 deposit is taken on a hosted payment checkout.
- The customer returns to
sunrinse.com/booked.
That is three domain changes, each one a chance to lose the source. For every hop, write down: who owns the destination, whether you can add code there, and whether it accepts URL parameters or hidden fields. That table decides your options.
| Hop | Can you add scripts? | Accepts URL parameters? | Best handoff |
|---|---|---|---|
| Ad to your site | Yes | Yes | UTMs and click IDs in the ad URL, stored on arrival |
| Your site to hosted booking page | Rarely | Often, into source or hidden fields | Append stored UTMs and click ID to the booking link |
| Booking to payment checkout | No | Via a reference ID set by the booking tool or your server | Pass your lead or booking ID as the payment reference |
| Payment back to your site | Yes | Yes, through the return URL | Include booking ID; exclude payment domain as a referrer |
Handoff methods, from simplest to most involved
Decorate outbound links with stored parameters
On landing, save the UTMs and click IDs to a first-party cookie or local storage. Then rewrite every link to the booking page so it carries them, for example:
https://book.vendor.com/sunrinse?utm_source=facebook&utm_medium=paid-social&utm_campaign=2026-09_den_spring-clean&fbclid=AbC123
This only works if the destination reads and stores the parameters. Many booking and form tools do, often into fields labelled as source or tracking; some need you to create hidden fields first. Test by making a booking and opening the record.
Analytics linker settings
Analytics tools can attach a temporary identifier to links between domains you list, so the receiving domain recognises the same visitor. In GA4 this is configured as cross-domain measurement in the data stream settings at the time of writing, and it appends a _gl parameter. It only helps when your analytics tag also runs on the destination, which is common for your own second domain and rare for a vendor's hosted page.
Reference IDs through payment
Payment checkouts almost never accept your scripts. Instead, create a booking or lead ID before sending the customer to pay, and pass it as the payment's reference or metadata field. Stripe Checkout, for example, supports a client reference field and metadata on the session. When the payment webhook arrives, you look up that ID and recover the original source from your own records. This is the most reliable method because it does not depend on the browser at all.
Return URL and referral exclusions
Set the post-payment return URL to include the booking ID, and add the payment provider's domain to your analytics' list of unwanted referrals so it does not take credit for the session. Check the current name and location of that setting in your analytics tool.
What the fix changes: a worked example
Say the Denver cleaning company had 71 paid bookings in a month according to its field-service software. Before the handoffs, analytics assigned them like this:
| Source in analytics | Bookings before | Bookings after |
|---|---|---|
| Booking vendor domain (referral) | 49 | 0 |
| Payment domain (referral) | 7 | 0 |
| Paid social | 8 | 44 |
| Paid search | 3 | 18 |
| Direct or unknown | 4 | 9 |
| Total | 71 | 71 |
Before, Meta and Google together showed 11 bookings. With roughly $3,900 of combined spend, that suggested about $355 per booking, high enough to cut the campaigns. After the handoffs, 62 bookings carried a paid source: about $63 per booking. Nothing about the ads changed. The bookings were always there; they had been credited to the scheduling tool and the payment page.
The direct or unknown row grew from 4 to 9 because a few bookings now arrived with a booking ID but no stored source, such as people who opened the link on another device. That residue is normal. Report it rather than spreading it across channels.
Embedded tools behave differently
Some booking tools and checkouts sit inside an iframe on your page rather than on a separate tab. The visitor never leaves your domain visually, but the iframe is still another domain, and modern browsers restrict its cookies. You usually cannot read what happens inside it directly. Many tools send messages from the iframe to the parent page when a step completes, which your own script can listen for. Calendly is a common example of this pattern, covered step by step in tracking Calendly bookings back to your ads.
Two related problems often get mistaken for cross-domain failures. Parameters dropped by redirects before the visitor ever reaches your site are covered in how redirects and link shorteners strip UTMs and click IDs. And if stored parameters expire before the visitor reaches the booking page, cookie lifetime is the issue, explained in first-party cookies and ad tracking.
FAQ
Why does my payment provider show up as a referral source in analytics?
The customer arrived on your thank-you page directly from the payment domain, so analytics treats it as a new referral. Add that domain to your unwanted referrals list and pass a booking ID through the return URL so the conversion can be tied to the original session.
Do I need cross-domain tracking for a subdomain like shop.mysite.com?
Subdomains of the same site can usually share cookies set on the parent domain, so many analytics tools handle them without extra setup. Separate registered domains, such as a vendor's booking page, always need an explicit handoff.
Can I add my tracking script to a hosted booking page I do not control?
Usually not, unless the vendor offers a field for tracking codes. Passing UTMs and click IDs in the booking link, and reading them from the booking record or webhook, is the dependable alternative.
Is the _gl linker parameter safe to leave in URLs?
It is a short-lived identifier meant to be read on arrival. It does not contain personal details, but it does make URLs messy, so avoid copying decorated links into ads, emails or bookmarks.
See your own numbers with the source attached
Adtrix connects Meta and Google Ads read-only, shows each ad next to its spend and reported results, and keeps CRM leads and booked calls in their own lane.