# Sources and campaigns

Each visit is counted with where it came from: the site that linked to it, or the tags on the link.

Google is one source however a visit reached it, and sources are grouped into Google Analytics’ channels, plus AI Assistants, so your figures line up with an ad platform’s. Your own campaigns are counted by the `utm_` tags on your links. Sources and channels need nothing from you.

## Sources

The Sources tab names where each visit came from. Google, Bing, DuckDuckGo, Facebook, Reddit, ChatGPT and about 150 others are named whichever of their addresses a visit came from, so Google counts `google.com`, `google.co.uk` and the Google app as one. Anywhere else is named by its host, such as `news.example.org`.

**Direct** is a visit with no referrer and no tag: an address typed or pasted, a bookmark, a link in an email or an app, or a link from a site that sends no referrer.

### Referrers

The Referrers tab has the host each visit came from, without `www.`, such as `google.co.uk`: the detail behind each source. Only the host is used, which is usually all a browser sends. Moving from one page of the site to another isn’t a referral, whether the page loads or a [single-page app](https://fiveb.ar/docs/single-page-apps.md#sources) moves to it, so a site is never a source of its own visits.

## Channels

The Channels tab groups your sources into the channels Google Analytics uses, so your figures line up with an ad platform’s. Organic Search is Google, Bing, DuckDuckGo and the other search engines, Organic Social is Facebook, Reddit, LinkedIn and the rest, and AI Assistants is ChatGPT, Claude, Perplexity, Gemini, Copilot and the other assistants. Click one to filter the dashboard by it.

A visit’s channel comes from its source and its `utm_medium` and `utm_campaign` tags, whatever their case. It’s worked out as your stats are read rather than when they’re counted, so every day already counted has its channels too. The channels are tried in this order, and the first that fits is the visit’s:

| Channel | A visit |
| --- | --- |
| Direct | With no referrer, and no source or medium tag, or with no medium and a source tag of exactly `Direct` |
| Cross-network | With a campaign containing `cross-network` |
| Paid Shopping | From a shop, such as Etsy, or with a shopping campaign, and with a paid medium |
| Paid Search | From a search engine, with a paid medium |
| Paid Social | From a social network or a messaging app, with a paid medium |
| Paid Video | From a video site, such as YouTube, with a paid medium |
| Display | With a medium of `display`, `banner`, `expandable`, `interstitial` or `cpm` |
| Paid Other | With any other paid medium |
| Organic Shopping | From a shop, or with a shopping campaign, such as `summer-shop` |
| Organic Social | From a social network or a messaging app, or with a medium of `social`, `social-network`, `social-media`, `sm`, `social network` or `social media` |
| Organic Video | From a video site, or with `video` in its medium |
| AI Assistants | From an AI assistant |
| Organic Search | From a search engine, or with a medium of `organic` |
| Email | From webmail or a Mailchimp link, or with `email`, `e-mail`, `e_mail`, `e mail` or `newsletter` in its source or medium |
| Affiliates | With a medium of `affiliate` |
| Audio | With a medium of `audio` |
| SMS | With a source or a medium of `sms` |
| Mobile Push Notifications | With a medium ending `push`, or containing `mobile` or `notification`, or with a source of `firebase` |
| Referral | From any other site, or tagged with a source and no medium, or with a medium of `referral`, `app` or `link` |
| Unassigned | With a medium none of the above knows, such as `qr` |

A shopping campaign has `shopping` in its name, or `shop` at its start, after an `e` or after anything but a letter: `summer-shop` and `eshop` are shopping campaigns, and `workshop` isn’t.

Some sites count where you might not expect: GitHub, Stack Overflow, Medium, WordPress, Blogger, Slack, Teams, Discord, Tripadvisor and Yelp are social networks, Google News is a search engine, and Wikipedia and Substack are Referral.

### How paid traffic is told apart

By the `utm_medium` tag. A medium containing `cp`, such as `cpc` or `cpm`, or one of `ppc`, `retargeting`, `ad` and `ads`, or starting `paid`, is paid: from a search engine it’s Paid Search, from a social network Paid Social. Tag your ads’ links, for example with `utm_source=google&utm_medium=cpc`.

fivebar doesn’t read the click IDs ad platforms add to a link yet, such as Google’s `gclid`, so an ad whose link has no `utm_medium`, an auto-tagged Google Ads link among them, counts as organic: from Google, it’s Organic Search. A source tag such as `adwords` or `fbads` names Google or Facebook, not an ad, so it’s paid only with a paid medium beside it.

### Compared with Google Analytics

- AI Assistants isn’t one of Google Analytics’ channels. It counts those visits as Referral, or as Unassigned for a link tagged `utm_source=chatgpt.com` alone, as ChatGPT tags its links.
- `ad` and `ads` are paid mediums here. Google Analytics tells a Google Ads click from its click ID instead.
- A visit from Gmail, Outlook, Yahoo Mail, Proton Mail or a Mailchimp link is Email, where Google Analytics counts it as Referral, and so is one with email or newsletter anywhere in its source or medium, not only one tagged exactly `email`.
- A link tagged with a source and no medium, such as `utm_source=partner`, is Referral, where Google Analytics has it as Unassigned: the source says where the visit came from.
- DuckDuckGo’s AI chat, `duck.ai`, is DuckDuckGo, so its visits are Organic Search.

## Tagging your links

Add tags to a link’s address to say where you put it, and the visits it brings are counted by them:

```
https://example.com/?utm_source=newsletter&utm_medium=email&utm_campaign=autumn
```

- `utm_source` is the source, in the Sources tab, in place of wherever the visit came from. `ref` and `source` do the same, for links tagged that way.
- `utm_medium`, `utm_campaign`, `utm_content` and `utm_term` are the Campaigns pane’s four tabs: Medium, Campaign, Content and Term.

### How tags are named

A source tag fivebar knows is counted under its name for that source, in any case: `google`, `fb`, `yt` and `chatgpt.com` are Google, Facebook, YouTube and ChatGPT, alongside the visits that came from those sites untagged. Any other tag is kept exactly as written, capitals and all, so `newsletter` and `Newsletter` are two sources: pick one spelling and stick to it.

Campaign tags are always kept as written. Each tag is cut to 120 characters.

## Read visits, not pageviews

Only the first pageview of a visit carries its source, channel and campaign, since the pages after it are reached from the site itself. So for traffic from a source, a channel or a campaign, read visits and visitors rather than pageviews: [Filters](https://fiveb.ar/docs/filters.md#what-each-figure-counts) says what each figure counts.
