Cross-device attribution without invasive tracking
By Devendra Variya, co-founder of Virling. Published 2026-11-22, updated 2026-11-25.
Cross-device attribution is crediting a sale to the visit that brought the buyer when they found you on one device and paid on another. Without fingerprinting it only works where the buyer identifies themselves on both devices, by logging in or by giving the same email. Everything else shows up as a second visitor, usually Direct, and the channel that did the work gets no credit.
Why cross-device journeys break attribution
Web analytics recognises a returning visitor by an ID stored in the browser, usually a first-party cookie. A phone and a laptop are two browsers, so they get two IDs. The phone has the visit from the post, the ad or the search. The laptop has a visit that started from a typed URL or a bookmark, and that is the one that reaches checkout.
The payment then joins to the laptop visitor, and the phone visit stays unconnected. The same thing happens between a work and a home computer, between two browsers on one machine, when someone clears cookies, and when Safari ITP expires them, and cookieless analytics cannot recognise a returning visitor past one day even on the same device. It is one reason Direct looks bigger than it should; see why Direct is your biggest traffic source. It also makes phones look worse than they are in a report of revenue by device.
Virling credits a payment from the visits of the visitor ID that checkout sends, so an ID you saved at a phone signup lets a laptop payment count toward the channel of that phone visit.
What can be joined, and what cannot
There are two ways to link two devices to one person:
- Something the person gives you: they sign up, log in or type their email on both devices. This is deterministic: the same account or the same email means the same person, and they chose to tell you.
- Something you guess: matching devices by IP address, screen size, fonts, browser version and similar traits. This is fingerprinting. It is unreliable on shared and mobile networks, the visitor never agreed to it, and browsers work actively to block it.
Only the first kind is worth doing. It will not join every journey. A visitor who browses on a phone without signing up and later buys on a laptop as a guest leaves nothing to join on, and no honest method will connect the two. Joined or not, the phone visit only counts if it falls inside the attribution window of the payment.
Practical steps
- Tag the links you share. Add UTM parameters to links in newsletters, social posts and messages. People often open these on a phone, and a tagged phone visit is at least recorded with its real source instead of Direct.
- Make it easy to continue later. If your product has accounts, let people sign up on the phone and pay later. The account then becomes the link between the two devices.
- Store the visitor ID on the account. When someone signs up, save the analytics visitor ID of that browser with their account. When they pay, from any device, pass that saved ID into checkout instead of the current browser's ID, so the sale joins to the device where they first arrived. That device's visits then appear in the journey whichever single-touch or multi-touch model you use to split the credit.
- Ask how they heard about you. A short question at signup or checkout catches what tracking misses on every device. Our how did you hear about us template has answer options and shows how to compare the answers with tracked sources.
- Report the gap as a gap. Keep unattributed sales on their own line instead of spreading them over channels by a formula, and compare them with the survey answers.
What Virling does here
Virling gives each browser one random visitor ID in the first-party virling_vid cookie, shared across your subdomains. It does not fingerprint visitors, and it never merges two visitor IDs into one. A phone and a laptop are two visitors in Virling too, so the days and visits before a first payment are counted from one visitor's sessions, and a journey split over two devices looks shorter than it was.
What it can join:
- The visitor ID you pass into checkout. A payment is credited from the sessions of whichever visitor ID reaches checkout, so the stored-ID step above works with no extra setup. See the checkout guide.
- An email at payment. Send the visitor's email as an
identifyevent, for example right after signup. Virling keeps only a SHA-256 hash of it with a salt of your site, never the email. A Stripe, Shopify or WooCommerce payment that arrives with no visitor ID and the same payer email is credited to that visitor and shows Matched by email on the Payments page. It applies to payments synced after the identify, and never crosses sites. See unattributed revenue. - The customer, for renewals. A subscription renewal takes the attribution of the customer's first payment, matched by the payment provider's customer ID, whichever device the renewal comes from.
What it does not do: guess that two devices are one person, match by IP address or device traits, or rewrite a visitor's history. If a laptop checkout carries the laptop's own visitor ID, the sale is credited to the laptop's sessions, even if the same person identified on a phone earlier. You can look around the demo first.
What to do this week: five steps
- Day 1: tag the links people open on a phone. Start with your newsletter, social bios and the messages you send. The social UTM link generator makes one link per platform, and the UTM builder covers the rest.
- Day 2: save the visitor ID at signup. Add one field to your accounts table and fill it from the
virling_vidcookie when the account is created. Write it once and never overwrite it at a later login. The checkout guide shows how to read the cookie. In cookieless mode there is no ID to save. - Day 3: pass the saved ID into checkout. Use the code from the checkout snippet generator, with the saved ID in place of the cookie and the cookie only when the account has none. Then test it: sign up on your phone from a tagged link, pay on your laptop in your provider's test mode, and follow test your setup to see which visit got the credit.
- Day 4: send the email for payments that skip checkout. An invoice or a payment link you send by email carries no visitor ID. If you use Stripe, Shopify or WooCommerce, send an
identifyevent right after signup, as in recover payments by email. The first browser that sends an email keeps it. - Day 5: ask the question and write down the gap. Add the how did you hear about us template to your signup form, and note last month's Direct and Unattributed revenue to compare with next month. Self-reported attribution covers how to read the answers.
One trade-off to know: a payment that carries the saved ID is credited from the visits of that first browser. A tagged visit made later on the laptop, such as a newsletter click, is not considered for it.
Example: one month before and after
Example only, with made-up numbers for an imaginary product at $30 a payment. Both columns show the same 40 payments and $1,200, first with each device on its own and then as they would be counted with the five steps in place:
| Made-up month | Before | After | What changed |
|---|---|---|---|
| Organic search | 8 ($240) | 11 ($330) | Two by the saved ID, one by email |
| Social | 3 ($90) | 7 ($210) | Three by the saved ID, one by email |
| 4 ($120) | 6 ($180) | Two by the saved ID, from a tagged newsletter link | |
| Direct | 19 ($570) | 13 ($390) | Seven left by the saved ID, one arrived by email |
| Unattributed | 6 ($180) | 3 ($90) | Three matched by email |
| All | 40 ($1,200) | 40 ($1,200) | Revenue does not change, only where it is counted |
The saved ID moved seven payments, $210, from the laptop's Direct visit to the visit on the phone. The email match moved three, $90, out of Unattributed, one of them to a visitor who had only Direct visits. The 16 payments left in Direct and Unattributed, $480, stay unknown to tracking. Some are people who really typed your address, and the rest cannot be told apart from them. Say five of those buyers named a source in the survey: that is a hint about the source, not a visit to credit.
What no tool can recover
- A phone visit by someone who never identifies there. If they do not sign up, log in or give an email on the phone, nothing on it says who they are. A tool that claims to join it is guessing.
- Two different emails. Signing up with a personal address and paying with a work one gives an email match nothing to match.
- A guest checkout on a new device. With no account and no visit except the one that paid, the first visit cannot be found.
- A visit whose ID was cleared before signup. When the cookie is gone, the earlier visits on that browser belong to another visitor ID.
- Journeys from before you set this up. An account made earlier has no saved ID, and the browser that found you may no longer hold the same one.
Frequently asked questions
What is cross-device attribution?
It is crediting a sale to the visit that brought the buyer when that visit happened on another device. Someone reads about you on a phone and pays on a laptop days later; cross-device attribution tries to connect the two.
Can cross-device journeys be joined without fingerprinting?
Only when the buyer tells you who they are on both devices, for example by signing up or logging in, or by giving the same email at signup and at checkout. Anything else means guessing from device traits, which is fingerprinting.
Does Virling join visitors across devices?
Not by itself. Each browser has its own visitor ID and visitors are never merged. You can send the email a visitor typed at signup as an identify event, and a Stripe, Shopify or WooCommerce payment with no visitor ID and the same payer email is then credited to that visitor. Virling keeps only a salted hash of the email.
Why do cross-device sales show up as Direct?
The device that pays often has no tagged visit. The buyer types your URL or opens a bookmark on the laptop, so the only session that device has is Direct, and the phone visit that brought them is on another visitor ID.
How do I find out where cross-device buyers came from?
Ask them. A short "how did you hear about us" question at signup or checkout catches what no tracking can, including word of mouth and podcasts, and it works on any device.
See which channels bring paying customers
Virling is open source under AGPL. Self-host it free, or use the hosted version with a 14-day free trial. It connects to Stripe, Paddle, Shopify, WooCommerce, Polar, LemonSqueezy, Dodo, Creem and RevenueCat.