GA4 Attribution Models and Custom Tracking Explained
Marketing attribution means giving credit for conversions to the right steps in a user’s journey. It helps you understand which activities drive results. This makes it easier to improve campaigns, set realistic goals, and spend your budget where it counts.
TL;DR
- GA4 has three attribution models: data-driven (default), paid and organic last click, and Google paid channels last click. First click, linear, time decay and position-based were removed in November 2023.
- The model setting changes credit only in event-scoped dimensions (key-event reports, explorations), not in the user and traffic acquisition reports.
- Set the lookback window to match your sales cycle: 7 or 30 days for acquisition events, 30, 60 or 90 days for other key events.
- For other models or full control, use the BigQuery export and build your own: rules in SQL, Markov or Shapley in Python.
Marketing attribution gives credit for conversions to the steps in a user’s journey that led to them. Without it, you overvalue some channels and overlook others. GA4 uses an event-based model rather than sessions, which changes how attribution is tracked and reported. For why attribution matters and how to use it in budget decisions, see attribution analysis; this article covers how it works in GA4.
Let your customers find you, wherever they look.
Which attribution models are available in GA4?
| Model | How it assigns credit | Best for | Available in 2026 |
|---|---|---|---|
| Data-driven (DDA) | Machine learning compares converting and non-converting paths (timing, device, number of ad interactions, order of channels) | Most sites, especially with complex journeys | Yes (default) |
| Paid and organic channels – last click | 100% to the last non-direct click; direct only if it’s the only touchpoint | Short sales cycles, comparisons with DDA | Yes |
| Google paid channels – last click | 100% to the last Google Ads click; if there’s none, falls back to paid and organic last click | Advertisers focused on Google Ads | Yes |
| First click | 100% to the first interaction | Acquisition and awareness analysis | No (removed Nov 2023); recreate in BigQuery |
| Linear | Equal credit to every touchpoint | A simple multi-touch view | No; recreate in BigQuery |
| Position-based | 40% first, 40% last, 20% split across the middle | Valuing both first and last contact | No; recreate in BigQuery |
| Time decay | More credit to touchpoints closer to conversion | Long sales cycles | No; recreate in BigQuery |
Data-driven attribution is available to all GA4 properties. Its algorithm isn’t public, and with few conversions its results are less stable. Google removed the four rule-based models in 2023 citing low use, and switched reports that used them to data-driven (SEL).

What do GA4 attribution settings change?
You’ll find them in Admin → Data display → Attribution settings:
- Reporting attribution model: data-driven, paid and organic last click, or Google paid channels last click.
- Lookback window: how far back GA4 looks for touchpoints. Acquisition key events (first_visit, first_open): 7 or 30 days (default 30). Other key events: 30, 60 or 90 days (default 90). Shorter windows can shift more credit to Direct.
- Channels that can receive credit when sharing key events with Google Ads: paid and organic, or Google paid channels only.
Important: the model affects only event-scoped traffic dimensions, such as session source in key-event reports and explorations. The User acquisition report always shows how users were first acquired, and Traffic acquisition shows the source of each session, regardless of the model (Google). That’s why the two reports show different numbers for the same channel. Google Ads conversions based on GA4 key events are reported in GA4 using last click.
To compare models, use Advertising → Attribution → Model comparison; to see the sequence of channels, use Conversion paths.
How do you build custom attribution models in BigQuery?
GA4 has a free, native export to BigQuery with raw, unsampled event data in daily and intraday (streaming) tables, kept as long as you want (Google). Standard properties can export up to 1 million events a day in the daily export; streaming costs extra, and history from before the link isn’t backfilled (costs).
For attribution, use the right traffic-source fields (Adswerve, schema):
| Field | What it contains | Since |
|---|---|---|
| traffic_source | How the user was first acquired (user scope) | From the start |
| collected_traffic_source | Campaign parameters collected with the event | May 2023 |
| session_traffic_source_last_click | Last-click source of the session, including Google Ads data | July 2024 (cross_channel_campaign from October 2024) |
With SQL you can recreate removed models (first click, linear, position-based, time decay), set your own lookback window and channel grouping, or apply business rules such as excluding brand search. With Python you can build data-driven models such as Markov chains or Shapley values. The query below compares first click, last click and linear credit by channel:
-- Channel credit by first click, last click and linear (GA4 BigQuery export)
-- Requires session_traffic_source_last_click (export from July 2024 onwards). Untested template.
WITH sessions AS (
SELECT
user_pseudo_id,
(SELECT value.int_value FROM UNNEST(event_params) WHERE key = 'ga_session_id') AS session_id,
MIN(event_timestamp) AS session_start,
ANY_VALUE(session_traffic_source_last_click.cross_channel_campaign.default_channel_group) AS channel,
COUNTIF(event_name = 'purchase') AS purchases,
SUM(IF(event_name = 'purchase', ecommerce.purchase_revenue, 0)) AS revenue
FROM `project.analytics_XXXXXX.events_*`
WHERE _TABLE_SUFFIX BETWEEN '20260101' AND '20260630'
GROUP BY 1, 2
),
paths AS ( -- sessions up to and including the first purchase, max 90 days back
SELECT s.*,
FIRST_VALUE(IF(purchases > 0, session_start, NULL) IGNORE NULLS)
OVER (PARTITION BY user_pseudo_id ORDER BY session_start
ROWS BETWEEN CURRENT ROW AND UNBOUNDED FOLLOWING) AS conv_ts
FROM sessions s
),
touches AS (
SELECT *,
ROW_NUMBER() OVER (PARTITION BY user_pseudo_id, conv_ts ORDER BY session_start) AS n,
COUNT(*) OVER (PARTITION BY user_pseudo_id, conv_ts) AS path_len,
MAX(revenue) OVER (PARTITION BY user_pseudo_id, conv_ts) AS conv_revenue
FROM paths
WHERE conv_ts IS NOT NULL
AND session_start >= conv_ts - 90 * 24 * 3600 * 1000000
)
SELECT
IFNULL(channel, '(not set)') AS channel,
SUM(IF(n = 1, conv_revenue, 0)) AS first_click_revenue,
SUM(IF(n = path_len, conv_revenue, 0)) AS last_click_revenue,
SUM(conv_revenue / path_len) AS linear_revenue
FROM touches
GROUP BY channel
ORDER BY linear_revenue DESC;
Custom models give control and transparency, but need SQL (and often Python) skills, computing budget, maintenance and clearly agreed rules. For full path analysis, see user paths in BigQuery; visualise the results in a BI tool (BI tools compared).

What are the limitations of GA4 attribution?
- Direct traffic: GA4 credits Direct when it finds no other source in the lookback window, often because a source wasn’t tracked.
- (not set): caused by tracking errors, processing delays or privacy settings.
- Consent and privacy: with consent mode v2 (required in the EEA since March 2024), users who decline are partly modelled (SEJ, cookieless measurement).
- Cross-device journeys: hard to connect without User-ID and logged-in users.
- Data retention: event-level data in explorations is kept 2 or 14 months (up to 50 in GA4 360); for longer analysis use BigQuery (Google).
- Channel groups: the default group can’t be edited, but you can create custom channel groups. Since May 2026 the default grouping includes an AI assistant channel (SEJ).
- Costs outside Google: import campaign cost data to compare ROAS across platforms (Google).
Improve your marketing impact with smarter attribution models.
Discover how assigning the right value to each customer touchpoint can boost your decision-making. Explore solutions tailored to your business needs.
What’s next for attribution in GA4?
Expect more modelled and aggregated data as privacy rules tighten, more AI-driven insights, and more value from first-party data and server-side tagging. Many advertisers now combine GA4 attribution with marketing mix modelling, such as Google’s open-source Meridian (Google), and incrementality tests.
FAQ
Which GA4 attribution model should I use?
Data-driven for most sites, compared regularly with paid and organic last click. Use custom models in BigQuery when you need rules GA4 doesn’t offer.
Can I still use first click or linear attribution in GA4?
Not in the interface; they were removed in November 2023. You can recreate them on BigQuery export data.
Why do User acquisition and Traffic acquisition show different numbers?
One shows how users were first acquired, the other the source of each session. The attribution model setting doesn’t change either.
Does changing the attribution model change historical data?
It applies to reports retroactively, but it doesn’t change the BigQuery export, which stores raw events.
Sources
- Analytics Help: Advertising and attribution
- Search Engine Land: Sunset details for 4 attribution models
- Analytics Help: Data retention
- Analytics Help: BigQuery Export and Export schema
- Adswerve: Four GA4 traffic source flavors in the BigQuery export
- Search Engine Journal: AI assistant channel in GA4
- Analytics Help: Import cost data
About the author: This article was prepared by the Insightland SEO and GEO team. Insightland is a Wrocław-based agency, part of the Hexe Capital Tech Hub, that connects business, tech and data: SEO and GEO, performance marketing, UX and analytics, and SEO and AI training. Contact us.