Unlock the power of Google Analytics with Big Query

Demystifying GA4’s Event-Scoped vs Session-Scoped Metrics in BigQuery

Demystifying GA4’s Event-Scoped vs Session-Scoped Metrics in BigQuery

One of the biggest shifts from Universal Analytics to GA4 is the way data is structured around events and scopes. Whether you’re analyzing campaigns, funnels, or user behavior, understanding the difference between event-scoped, session-scoped, and user-scoped metrics is critical.

In this post, we’ll use BigQuery SQL to show how scope affects your numbers — with a practical ecommerce funnel example.

Official documentation: Scopes in GA4


1. Event Scope: Counting at the Granular Level

Event scope means every row in BigQuery represents a single event (like view_item, add_to_cart, or purchase).

SQL Example: Count total product views (event-scoped)

SELECT
  COUNT(*) AS total_product_views
FROM
  `your_dataset.analytics_XXXX.events_*`
WHERE
  event_name = 'view_item'
  AND _TABLE_SUFFIX BETWEEN '20250801' AND '20250815'

How this SQL works:


2. Session Scope: Rolling Events into Sessions

Sometimes you want to know how many sessions included an action, not how many times it happened.

SQL Example: Count sessions where at least one add-to-cart occurred

SELECT
  COUNT(DISTINCT CONCAT(user_pseudo_id, CAST(event_bundle_sequence_id AS STRING))) AS sessions_with_cart
FROM
  `your_dataset.analytics_XXXX.events_*`
WHERE
  event_name = 'add_to_cart'
  AND _TABLE_SUFFIX BETWEEN '20250801' AND '20250815'

How this SQL works:


3. User Scope: Unique People Behind Events

Finally, you may want to know how many unique users performed an action.

SQL Example: Count unique users who purchased

SELECT
  COUNT(DISTINCT user_pseudo_id) AS users_purchased
FROM
  `your_dataset.analytics_XXXX.events_*`
WHERE
  event_name = 'purchase'
  AND _TABLE_SUFFIX BETWEEN '20250801' AND '20250815'

How this SQL works:


4. Checkout Funnel Example: How Scope Changes the Numbers

Let’s say we want to analyze a 3-step funnel: view → cart → purchase.

Event Scope Query (all raw actions):

SELECT
  event_name,
  COUNT(*) AS event_count
FROM
  `your_dataset.analytics_XXXX.events_*`
WHERE
  event_name IN ('view_item', 'add_to_cart', 'purchase')
  AND _TABLE_SUFFIX BETWEEN '20250801' AND '20250815'
GROUP BY
  event_name

Session Scope Query (sessions with the action):

SELECT
  event_name,
  COUNT(DISTINCT CONCAT(user_pseudo_id, CAST(event_bundle_sequence_id AS STRING))) AS session_count
FROM
  `your_dataset.analytics_XXXX.events_*`
WHERE
  event_name IN ('view_item', 'add_to_cart', 'purchase')
  AND _TABLE_SUFFIX BETWEEN '20250801' AND '20250815'
GROUP BY
  event_name

User Scope Query (unique users per step):

SELECT
  event_name,
  COUNT(DISTINCT user_pseudo_id) AS users_count
FROM
  `your_dataset.analytics_XXXX.events_*`
WHERE
  event_name IN ('view_item', 'add_to_cart', 'purchase')
  AND _TABLE_SUFFIX BETWEEN '20250801' AND '20250815'
GROUP BY
  event_name

Why the numbers differ:


Conclusion

Understanding scope in GA4 BigQuery is key to avoiding misinterpretation. If your funnel drop-offs look huge, check whether you’re analyzing at the event, session, or user level.

When in doubt, ask yourself:

For further reference, check the official GA4 Scopes documentation.

Discover more from GA4 BigQuery

Subscribe now to keep reading and get access to the full archive.

Continue reading