Referrers, links, and cross-navigation events
Understanding how users arrive at your pages and navigate between them is essential for analyzing traffic sources, marketing effectiveness, and user journeys. Snowplow captures referrer information, deep link data, and link click events to give you a complete picture of cross-page and cross-app navigation.
Referrer atomic event property
Some Snowplow trackers can populate the page_referrer atomic event property. This field captures the URL of the page that referred the user to the current page.
This table shows the support for page referrer tracking across the main client-side Snowplow tracker SDKs. The server-side trackers don't include referrer tracking.
| Tracker | Supported | Since version | Auto-tracking | Notes |
|---|---|---|---|---|
| Web | ✅ | 0.1.0 | ✅ | Automatic for all page view events |
| iOS | ✅ | 3.0.0 (deep link events), 4.1.0 (deep link entity) | ❌ | Based on Deep Link events |
| Android | ✅ | 3.0.0 (deep link events), 4.1.0 (deep link entity) | ❌ | Based on Deep Link events |
| React Native | ✅ | 1.1.0 | ❌ | Based on Deep Link events |
| Flutter | ❌ | |||
| Roku | ❌ | |||
| Google Tag Manager | ✅ | v3 | ✅ | Automatic for all page view events |
The web trackers automatically populate the page_referrer atomic event property in all page view events.
Deep links for mobile
Deep links are URLs or hyperlinks that take users directly to a particular location within a mobile app. They're received by the mobile operating system and passed to the related app.
Most events tracked on mobile unsurprisingly don't include webpage atomic properties. However, the mobile trackers can capture both the URL of the deep link and the referrer URL (if available).
You'll need to manually track any received deep links, using the deep_link_received event.
The deep_link_received event, as well as the first subsequent screen view event, include the page_url and page_referrer atomic event properties.
deep_link_received
EventExample
{
"url": "https://example.com/notes/123",
"referrer": "https://snowplow.io"
}
Properties and schema
- Table
- JSON schema
| Property | Description |
|---|---|
urlstring | Required. URL in the received deep-link |
referrerstring | Optional. Referrer URL, source of this deep-link |
{
"$schema": "http://iglucentral.com/schemas/com.snowplowanalytics.self-desc/schema/jsonschema/1-0-0#",
"description": "Represents a deep-link received in the app.",
"self": {
"vendor": "com.snowplowanalytics.mobile",
"name": "deep_link_received",
"format": "jsonschema",
"version": "1-0-0"
},
"type": "object",
"properties": {
"url": {
"type": "string",
"description": "URL in the received deep-link",
"format": "uri",
"maxLength": 4096
},
"referrer": {
"type": "string",
"description": "Referrer URL, source of this deep-link",
"format": "uri",
"maxLength": 4096
}
},
"required": [
"url"
],
"additionalProperties": false
}
Warehouse query
- Snowflake
- BigQuery
- Databricks
- Redshift & Postgres
select
unstruct_event_com_snowplowanalytics_mobile_deep_link_received_1 deep_link_received_1
from
atomic.events
where
events.collector_tstamp > getdate() - interval '1 hour'
and events.event = 'unstruct'
and events.event_name = 'deep_link_received'
and events.event_vendor = 'com.snowplowanalytics.mobile'
select
unstruct_event_com_snowplowanalytics_mobile_deep_link_received_1_0_0
from
PIPELINE_NAME.events events
where
events.collector_tstamp > timestamp_sub(current_timestamp(), interval 1 hour)
and events.event = 'unstruct'
and events.event_name = 'deep_link_received'
and events.event_vendor = 'com.snowplowanalytics.mobile'
select
unstruct_event_com_snowplowanalytics_mobile_deep_link_received_1
from
atomic.events events
where
events.collector_tstamp > timestampadd(HOUR, -1, current_timestamp())
and events.event = 'unstruct'
and events.event_name = 'deep_link_received'
and events.event_vendor = 'com.snowplowanalytics.mobile'
and unstruct_event_com_snowplowanalytics_mobile_deep_link_received_1 is not null
select
"deep_link_received_1".*
from
atomic.events events
join atomic.com_snowplowanalytics_mobile_deep_link_received_1 "deep_link_received_1"
on "deep_link_received_1".root_id = events.event_id and "deep_link_received_1".root_tstamp = events.collector_tstamp
where
events.collector_tstamp > getdate() - interval '1 hour'
and "deep_link_received_1".root_tstamp > getdate() - interval '1 hour'
and events.event = 'unstruct'
and events.event_name = 'deep_link_received'
and events.event_vendor = 'com.snowplowanalytics.mobile'
The tracker will automatically add this deep_link entity to the next screen view event after tracking the deep_link_received event.
deep_link
EntityExample
{
"url": "https://example.com/notes/123",
"referrer": "https://snowplow.io"
}
Properties and schema
- Table
- JSON schema
| Property | Description |
|---|---|
urlstring | Required. URL in the received deep-link |
referrerstring | Optional. Referrer URL, source of this deep-link |
{
"$schema": "http://iglucentral.com/schemas/com.snowplowanalytics.self-desc/schema/jsonschema/1-0-0#",
"description": "Entity that indicates a deep-link has been received and processed.",
"self": {
"vendor": "com.snowplowanalytics.mobile",
"name": "deep_link",
"format": "jsonschema",
"version": "1-0-0"
},
"type": "object",
"properties": {
"url": {
"type": "string",
"description": "URL in the received deep-link",
"format": "uri",
"maxLength": 4096
},
"referrer": {
"type": "string",
"description": "Referrer URL, source of this deep-link",
"format": "uri",
"maxLength": 4096
}
},
"required": [
"url"
],
"additionalProperties": false
}
Link clicks
The web trackers can automatically track link click events, capturing details about the clicked link such as its URL, element ID, classes, target, and content.
This table shows the support for link click tracking across the main client-side Snowplow tracker SDKs. The server-side trackers don't include link click tracking.
| Tracker | Supported | Since version | Auto-tracking | Notes |
|---|---|---|---|---|
| Web | ✅ | 0.7.0 (limited functionality), 3.0.0 (plugin) | ✅ | Requires link click plugin |
| iOS | ❌ | |||
| Android | ❌ | |||
| React Native | ❌ | |||
| Flutter | ❌ | |||
| Roku | ❌ | |||
| Google Tag Manager | ✅ | v3 | ✅ | Integrates with link click plugin |
To track link clicks on web using React Native or Flutter, you can implement custom event tracking when users interact with links in your app using the link_click event schema.
We recommend using the Base web tracking plan template for web tracking. It includes link clicks.
link_click
EventProperties and schema
- Table
- JSON schema
| Property | Description |
|---|---|
elementIdstring | Optional. |
elementClassesarray | Optional. |
elementTargetstring | Optional. |
targetUrlstring | Required. |
elementContentstring | Optional. |
{
"$schema": "http://iglucentral.com/schemas/com.snowplowanalytics.self-desc/schema/jsonschema/1-0-0#",
"description": "Schema for a link click event",
"self": {
"vendor": "com.snowplowanalytics.snowplow",
"name": "link_click",
"format": "jsonschema",
"version": "1-0-1"
},
"type": "object",
"properties": {
"elementId": {
"type": "string"
},
"elementClasses": {
"type": "array",
"items": {
"type": "string"
}
},
"elementTarget": {
"type": "string"
},
"targetUrl": {
"type": "string",
"minLength": 1
},
"elementContent": {
"type": "string"
}
},
"required": [
"targetUrl"
],
"additionalProperties": false
}
Warehouse query
- Snowflake
- BigQuery
- Databricks
- Redshift & Postgres
select
unstruct_event_com_snowplowanalytics_snowplow_link_click_1 link_click_1
from
atomic.events
where
events.collector_tstamp > getdate() - interval '1 hour'
and events.event = 'unstruct'
and events.event_name = 'link_click'
and events.event_vendor = 'com.snowplowanalytics.snowplow'
select
unstruct_event_com_snowplowanalytics_snowplow_link_click_1_0_1
from
PIPELINE_NAME.events events
where
events.collector_tstamp > timestamp_sub(current_timestamp(), interval 1 hour)
and events.event = 'unstruct'
and events.event_name = 'link_click'
and events.event_vendor = 'com.snowplowanalytics.snowplow'
select
unstruct_event_com_snowplowanalytics_snowplow_link_click_1
from
atomic.events events
where
events.collector_tstamp > timestampadd(HOUR, -1, current_timestamp())
and events.event = 'unstruct'
and events.event_name = 'link_click'
and events.event_vendor = 'com.snowplowanalytics.snowplow'
and unstruct_event_com_snowplowanalytics_snowplow_link_click_1 is not null
select
"link_click_1".*
from
atomic.events events
join atomic.com_snowplowanalytics_snowplow_link_click_1 "link_click_1"
on "link_click_1".root_id = events.event_id and "link_click_1".root_tstamp = events.collector_tstamp
where
events.collector_tstamp > getdate() - interval '1 hour'
and "link_click_1".root_tstamp > getdate() - interval '1 hour'
and events.event = 'unstruct'
and events.event_name = 'link_click'
and events.event_vendor = 'com.snowplowanalytics.snowplow'
Cross-domain tracking
Read more about tracking cross-domain in the cross-navigation page.