AI-generated Key Takeaways
-
This guide provides instructions for implementing conversion tracking using Google Tag Manager (GTM) for websites already utilizing GTM.
-
The process involves creating two tags: a Custom HTML Tag to store the
rwg_token
for 30 days and a GA4 Event Tag to send therwg_token
to Google Analytics. -
The Custom HTML Tag extracts and persists the
rwg_token
URL parameter, which is crucial for tracking conversions originating from Google Place Action links. -
The GA4 Event Tag is configured with a specific Measurement ID, event name (
rwg_conversion
), and event parameter (rwg_token
) to forward conversion data to Google Analytics. -
Ensure no Personally Identifiable Information (PII) is sent to Google without explicit user consent or legal permission.
Instructions
There are 2 steps for implementing conversion tracking:
- Create a new Custom HTML Tag
- Create a new Google Analytics: GA4 Event Tag
Custom HTML Tag
To properly track conversions from action_link
(s), Google will
set a URL parameter rwg_token
, which should be returned at the
time of a conversion.
You will be required to persist the rwg_token
URL parameter
which will be appended to all action_link
(s) provided by you for
a duration of 30 days when a user visits the landing page via Google. If a
user visits the page through an action link again during the 30 day period,
the existing rwg_token
should be replaced with a new token, and
the 30 day time to live should be reset. The suggested way to persist this
information is via cookies.
Our recommended approach to persist the rwg_token
is to create
a custom HTML tag, which is fired on every page view. The custom HTML tag
should contain javascript which extracts the rwg_token
form the
url parameter and persists the rwg_token
for 30 days. You can
persist the data using 1st Party Cookies or a Data Layer Variable.
Google Analytics: GA4 Event Tag
GA4 Event Tag allows you to forward the rwg_token
to Google
using the correct measurement ID.
When configuring the GA4 Event Tag, you are required to initiate the following fields:
- Configuration Tag: Set this to
None : Manually set ID
. - Measurement ID Set the appropriate Measurement ID for your account.
- Event Name: Set this to
rwg_conversion
- Event Parameter: Add a new Event Parameter
rwg_token
. The value of this token should be the persisted value of the token.
Each GA4 Event Tag needs to be associated with a Trigger. You should create a trigger which fires this event tag when a user completes a transaction which originated from a Google Place Action link.