Google Ads (Gtag) Destination
Destination Info
- Accepts Page, and Track calls.
- Referred to as Google AdWords New, or Google Ads (Google Tag Manager), or Google Ads (Gtag) in the Integrations object
Components
Before you begin
If you’re using the new Google Ads (Gtag) experience, you can enable the Google Ads (Gtag) Destination (previously called “Google Adwords New”) in the Segment catalog. The new Google Ads uses a Global Site Tag (Gtag) and event snippets.
Info message.
IMPORTANT: Only use this destination if your Google Ads account is using the New (Gtag) Experience. If you’re using Google Tag Manager (a separate product) as well, don’t add the global site tag again in your GTM containers. You should also disable any Google Ads (Classic) destinations within the same source, since Google Ads (Classic) can’t load at the same times as Google Ads (Gtag).
Getting Started
You can use this destination to map your .page()
calls to Page Load Conversions or .track()
calls to Click Conversions.
Currently this is only supported on the browser.
Page
If you want to map all your unnamed .page()
calls to a default Page Load Conversion, you can enter the AdWords Conversion ID in Settings > Default Page Conversion. However, if you created specific Page Load Conversions in Google Ads that you’d like to map your named .page()
calls in Segment, you can map the events in Settings > Page Load Conversions.
Segment forwards all the properties
of the page call, such as path
, title
, url
, because by default, Google Ads (Gtag) makes these available in your remarketing campaigns.
You can send Google’s semantic properties, such as value
, currency
, or transaction_id
, as integration specific options. However, Segment recommends you to create a Click Conversion instead, and map them to .track()
calls. The example below shows these properties as integration-specific options:
analytics.page({}, {
'Google Adwords New': {
value: 25,
currency: 'USD',
order_id: 'order123'
}
});
NOTE: The 'Google Ads (Gtag)'
is case sensitive. Segment prefers you to use order_id
rather than transaction_id
to stay more consistent with the ecommerce spec. However, Segment will send it as transaction_id
in the request itself to satisfy Google’s specifications.
Track
You can map your custom .track()
events to any Click Conversions you created inside Google Ads. Segment passes any properties
so you can use them during your remarketing campaigns.
If you pass properties.value
, properties.currency
, or properties.order_id
, Segment maps them to Google’s semantic value
, currency
, or transaction_id
respectively.
The only exception is that for Order Completed
events, Segment will map Google’s semantic value
field to your properties.revenue
.
Troubleshooting AdWords Conversions
To figure out if an event is flagged for Conversion by the AdWords SDK, follow these steps:
- Confirm that the events mapped to Google Ads Conversion are being sent in device-mode while using the Segment Analytics.js library. To do this:
- Go to Connections > Sources in your workspace and choose your Source.
- Go to the Debugger tab.
- Click on an event and look at the Raw view to make sure the events have a library name of
analytics.js
. There should be a snippet of code that looks like this:
"library": { "name": "analytics.js",
- Verify that the Google Conversion ID in your Segment workspace is correct.
- Find your ad online and click on it. This will redirect you to your website.
-
Open the Network tab in your browser and make sure the Preserve log checkbox is checked and All is selected. Keep this Network tab and webpage open.
-
Go to the Settings tab for your Gtag destination in Segment on a new webpage and choose Click Conversions to look at the mapped
track()
events and make sure the events are mapped to the correct Adwords Conversion Label. - Go back to your website and trigger the event mapped to the conversion. For example, as shown in the image above, it would be
Order Completed
. -
Go to the Network tab in your browser and enter the Adwords Conversion Label linked to the event you triggered in the Filter field.
- See if the value for the
ct_cookie_present
changed totrue
. Iftrue
, it means that Adwords counts the event as a conversion.
Multiple Google Ads Accounts
If you are an enterprise that uses multiple Google Ads Gtag accounts (usually managed by various third party agencies) you can override the top level default Google Conversion ID at the event level by entering it into the settings.
Supported Sources and Connection Modes
Before you start, make sure Google Ads (Gtag) supports the source type and connection mode you’ve chosen to implement. You can learn more about connection modes here.
Web | Mobile | Server | |
---|---|---|---|
📱 Device-mode | ✅ | ⬜️ | ⬜️ |
☁️ Cloud-mode | ⬜️ | ⬜️ | ⬜️ |
Settings
Segment lets you change these destination settings from the Segment app without having to touch any code.
Setting | Description |
---|---|
Google Conversion ID (required) |
string . Enter your GOOGLE-CONVERSION-ID. You can get this value from your global site tag snippet. It should look something like AW-901243031 |
Click Conversions (required) |
mixed , defaults to . You can map your .track() events to specific AdWords Click Conversions by providing your event name and the Conversion ID. |
Conversion Linker | boolean , defaults to TRUE . If you don’t want the global site tag to set first-party cookies on your site’s domain, you should disable this setting. Disabling this is NOT recommended by Google as it can lead to less accurate conversion measurements. |
Default Page Conversion | string . If you want to map all your default .page() calls that do not explicitly pass in a name to a conversion event, you can enter the Adwords Conversion ID here. |
Disable Ad Personalization (required) |
boolean , defaults to FALSE . Enable this setting to to disable the collection of remarketing data for users who do not wish to view personalized ads. When enabled, Segment will set the allow_ad_personalization_signals AdWords tag parameter to false . For more information about disabling the collection of remarketing data see Google’s documentation here. |
Page Load Conversions (required) |
mixed , defaults to . You can map your .page() calls to specific AdWords Page Load Conversions by providing your page name and the Conversion ID. |
Send Page View | boolean , defaults to TRUE . If you want to prevent the global site tag from automatically sending a remarketing hit to your AdWords accounts when the page is viewed, you can disable this setting. Otherwise, by default all properties sent with the conversions will be sent as remarketing hits which will allow you to create audiences based on those properties. |
Adding Google Ads (Gtag) to the integrations object
To add Google Ads (Gtag) to the integrations
JSON object (for example, to filter data from a specific source), use one of the following valid names for this integration:
- Google AdWords New
This page was last modified: 11 Nov 2021
Need support?
Questions? Problems? Need more info? Contact Segment Support for assistance!