# Track additional domains

Send data from several domains to one website, and keep one visitor across them with supr-allowed-hostnames, so a payment on one credits visits on another.

A website accepts hits from its domain and its subdomains. If the same product lives on other domains too (`yourproduct.io` and `yourproduct.com`, or a docs site elsewhere), add them in Settings → General → Additional domains (up to 20). Their subdomains are included.

Hits from any other domain are refused, so nobody can send fake data to your website from theirs.

## One visitor across domains

Cookies can't be shared between different domains. To keep a person who follows a link from one of your domains to another as **one visitor** (and credit a payment made on the second one to where they first came from), list all your domains in `supr-allowed-hostnames` and install the same snippet on each. The snippet in Settings → General does this for you once additional domains are set.

```
<script defer supr-website-id="YOUR_WEBSITE_ID" supr-domain="yourproduct.com" supr-allowed-hostnames="yourproduct.com,yourproduct.io" src="…/js/script.js"></script>
```

- When a link to another listed domain is clicked, the script adds `_supr_vid`, `_supr_sid` and `_supr_ts` to it. The page there takes the visitor and visit over and removes them from the address bar.
- The visit continues: no new session, no referral, and the click isn't counted as an exit link.
- The ids are only taken from links under 2 minutes old, so a link someone copies and shares later doesn't merge strangers.
- Only clicked links are decorated. For a redirect or form post from your server, add the parameters yourself from `supr.visitorId()` and `supr.sessionId()`.
- `supr-domain` only applies on its own domain; elsewhere the script keeps the cookie on the current one.

> Visitors who reach another domain without such a link (typing the address, a bookmark) still count separately. Use [identify](https://supranalytics.app/docs/user-identification.md) to name them on both.

---

This page on the web: https://supranalytics.app/docs/cross-domain-tracking
Every documentation page: https://supranalytics.app/docs.md
