Revenue per Visit
Revenue per visit measures the average revenue generated each time a user visits the website. It is crucial for understanding the effectiveness of the website in converting visits into revenue.
Business Use Case
An e-commerce growth team monitors revenue per visit by channel and device. If paid social drives high traffic but low revenue per visit compared with email, the team can reduce spend on low-value campaigns, improve landing page relevance, or retarget higher-intent audiences.
Business Criticality
High
Journey / Navigation Area
Digital Analytics
Scope
Session
Formula
Total Revenue / Total VisitsCalculation Notes
1️⃣ Use visits as sessions, not users or pageviews. 2️⃣ Include only completed revenue events (purchases, paid conversions). 3️⃣ Exclude refunds, canceled orders, test transactions, internal traffic, bot traffic, and duplicate purchases. 4️⃣ Subtract refunds from gross revenue for net revenue per visit. 5️⃣ Ensure consistent sessionization logic across web and app data. 6️⃣ Deduplicate sessions in cross-domain implementations where identity stitching is available.
Technical Details
Events
| Platform | Event |
|---|---|
| Google Analytics 4 | purchase |
| Adobe | purchase |
Data Mappings
W3 Data Layer
{
"event": "purchase",
"ecommerce": {
"transaction_id": "T12345",
"currency": "USD",
"value": 149.99,
"items": [
{
"item_id": "SKU-001",
"item_name": "Running Shoes",
"price": 149.99,
"quantity": 1
}
]
},
"web": {
"webPageDetails": {
"URL": "https://www.example.com/checkout/confirmation"
}
}
}GA4 Data Layer
{
"event": "purchase",
"ecommerce": {
"transaction_id": "T12345",
"currency": "USD",
"value": 149.99,
"tax": 12.5,
"shipping": 0,
"items": [
{
"item_id": "SKU-001",
"item_name": "Running Shoes",
"price": 149.99,
"quantity": 1
}
]
}
}Adobe Client Data Layer
{
"event": "purchase",
"commerce": {
"order": {
"purchaseID": "T12345",
"currencyCode": "USD",
"priceTotal": 149.99
},
"productListItems": [
{
"SKU": "SKU-001",
"name": "Running Shoes",
"priceTotal": 149.99,
"quantity": 1
}
]
}
}XDM Mapping
{
"eventType": "commerce.purchases",
"commerce": {
"order": {
"purchaseID": "T12345",
"priceTotal": 149.99,
"currencyCode": "USD"
}
},
"productListItems": [
{
"SKU": "SKU-001",
"name": "Running Shoes",
"priceTotal": 149.99,
"quantity": 1
}
],
"web": {
"webPageDetails": {
"URL": "https://www.example.com/checkout/confirmation"
}
}
}SQL Queries
Google Analytics 4 (BigQuery)
WITH session_revenue AS ( SELECT user_pseudo_id, user_id, CONCAT(user_pseudo_id, '-', CAST((SELECT value.int_value FROM UNNEST(event_params) WHERE key = 'ga_session_id') AS STRING)) AS session_id, SUM(COALESCE((SELECT SUM(CAST(item.revenue AS FLOAT64)) FROM UNNEST(items) AS item), 0)) AS revenue FROM `project.dataset.events_*` WHERE event_name = 'purchase' GROUP BY 1, 2 ), sessions AS ( SELECT DISTINCT user_pseudo_id, user_id, CONCAT(user_pseudo_id, '-', CAST((SELECT value.int_value FROM UNNEST(event_params) WHERE key = 'ga_session_id') AS STRING)) AS session_id FROM `project.dataset.events_*` WHERE (SELECT value.int_value FROM UNNEST(event_params) WHERE key = 'ga_session_id') IS NOT NULL ) SELECT SAFE_DIVIDE(SUM(COALESCE(sr.revenue, 0)), COUNT(DISTINCT s.session_id)) AS revenue_per_visit FROM sessions s LEFT JOIN session_revenue sr ON s.session_id = sr.session_id;Adobe Experience Platform (AEP Query Service)
WITH session_revenue AS ( SELECT identityMap.ECID[0].id AS mcid, session_id, SUM(COALESCE(commerce.purchases.value, 0)) AS revenue FROM dataset.events WHERE eventType = 'commerce.purchases' GROUP BY 1, 2 ), sessions AS ( SELECT DISTINCT identityMap.ECID[0].id AS mcid, session_id FROM dataset.events WHERE session_id IS NOT NULL ) SELECT COALESCE(SUM(sr.revenue), 0) / NULLIF(COUNT(DISTINCT s.session_id), 0) AS revenue_per_visit FROM sessions s LEFT JOIN session_revenue sr ON s.session_id = sr.session_id;Source Data
Digital Analytics, Business Intelligence, ERP
Dependencies
Prerequisite: List the dependencies required for this KPI
Events:
Metrics:
Report Attributes
Dimensions: Default channel group, Source/Medium, Campaign, Device category, Landing page, Country, New vs Returning Metrics: Revenue, Sessions, Transactions, Conversion rate, Average order value, Revenue per visit
Recommended Reporting Views
Segment Eligibility
True
Governance
Governance
GitHub
catalog/kpis/revenue-per-visit.yml