Google Ads Sync (Decoupled)
What is Google Ads Sync?
The Google Ads sync fires conversion events to Google Ads via the gtag.js library. It sends conversion events with specific labels that can be tracked in your Google Ads account for attribution and optimization.
Considerations
- Cookie Lifetime - GCLID, DCLID, and WBRAID cookie lifetimes are managed by the parent Google Tag Settings, not this sync. Set them to align with your Google Ads conversion window to avoid
EXPIRED_EVENTerrors. - Processing Delay - Google recommends delaying conversion uploads to ensure identifiers are fully available before delivery:
| Identifier | Recommended Delay |
|---|---|
gclid | ~1 hour after click |
wbraid | ~1 hour after click |
- To enable event delay - Contact your MetaRouter Customer Support Rep to configure delay for Google Ads conversions (recommended: ~1 hour for gclid/dclid).
- Partial Failure Responses - The Google Ads API returns HTTP 200 even when individual conversions fail. Errors such as
EXPIRED_EVENTorUNAUTHORIZED_CUSTOMERappear in the response body and do not trigger automatic retry. Monitor response bodies or GCP logs to catch silent conversion failures. For a full list of error codes and fixes, see the Google Ads - Conversions documentation. - IAB TCF Consent - Enabling IAB TCF Consent requires an IAB TCF v2.0-compliant CMP with the
__tcfapiJavaScript API exposed on the site, and Consent Policy set to "Explicit Consent" in MetaRouter Advanced Settings. Vendor ID is 755. - CMP Compatibility - This sync works with any CMP provided the consent categories are configured correctly in the MetaRouter UI.
Architecture Overview
- Google Tag Settings serves as the parent and controls gtag.js library loading
- Google Ads is a child sync with its own conversion event configuration
- The sync sends conversion events via
gtag('event', 'conversion', {...}) - The parent gtag must be deployed before Google Ads sync can function
Google Tag Settings (Parent)
├── GTAG.js Tag ID
├── Load GTAG library
├── Load GTAG when zero consent granted
│
└── Syncs (Children)
├── Google Ads (sends conversion events)
├── Google Analytics 4 (optional)
└── Google Campaign Manager 360 (optional)
Prerequisites
Before configuring the Google Ads sync:
- Parent Google Tag Settings must be configured — The parent controls gtag.js library loading and must be deployed first
- Google Ads account with conversion actions — You need your Ads ID (AW-XXXXXXX) and conversion labels
Configuration Fields
Parent Fields (Google Tag Settings)
| Field | Description | Required |
|---|---|---|
| GTAG.js Tag ID | Your Google Ads ID (e.g., AW-XXXXXXX) or GA4 Measurement ID. | No* |
| Load GTAG library | Toggle to load the gtag.js library. Must be ON for Google Ads sync to function. | Yes |
| Load GTAG when zero consent granted | When ON, loads gtag even when no consent categories are granted. | Yes |
*GTAG.js Tag ID can be specified in the parent or in conversion events.
Google Ads Sync Fields
| Field | Description | Required | Default |
|---|---|---|---|
| Consent Type | Consent category required before sync fires (e.g., C0004 - Targeting Sales). | Yes | — |
| IAB TCF Consent | Enable IAB Transparency & Consent Framework integration. Vendor ID: 755. | No | Disabled |
| Conversions | Array of conversion events to fire. Each with adsID and label. | Yes | — |
Conversions Array Format
[
{
"adsID": "AW-111111111",
"label": "conversion_label_1"
},
{
"adsID": "AW-111111111",
"label": "conversion_label_2"
}
]Setup
1. Configure Parent Google Tag Settings
- From the Pipelines page, find the pipeline associated with your web property
- Hover over the three-dot dropdown and select "Build AJS File"
- In the Identity Syncs section, add Google Tag Settings
- Configure the parent fields:
- GTAG.js Tag ID: Enter your Google Ads ID (e.g.,
AW-111111111) or leave blank - Load GTAG library: Set to ON
- Load GTAG when zero consent granted: Set based on your consent requirements
- GTAG.js Tag ID: Enter your Google Ads ID (e.g.,
2. Add Google Ads Sync
- Under the Syncs section within Google Tag Settings, add Google Ads
- Configure the sync fields:
- Consent Type - Select the consent category required before the sync fires (typically
C0004 - Targeting Salesfor advertising). - IAB TCF Consent - Enable if using IAB TCF v2.0-compliant CMP. The Google Ads sync uses vendor ID 755.
- Conversions - Enter your conversion events array:
[
{
"adsID": "AW-111111111",
"label": "purchase_conversion"
}
]3. Save and Deploy
- Click Save and Build File
- Deploy your AJS file to propagate changes to your web property
Technical Details
Sync Behavior
The sync executes the following steps:
- Checks gtag.js availability (must be loaded by parent Google Tag configuration)
- Fires conversion events for each configured conversion:
gtag('event', 'conversion', {
send_to: `${adsID}/${label}` // e.g., "AW-111111/purchase_conversion"
});- Stores marker to prevent duplicate firing
Storage Markers
| Storage Type | Key | TTL |
|---|---|---|
| Cookie/IndexedDB | [prefix]_googleAds_gtag_called | 365 days |
Server-Side Enrichment
Adds to context.providers.googleAds:
{
"googleAds": {
"fired": "Wed Nov 27 2024 13:31:52 GMT+0300 (GMT+03:00)"
}
}Verification
- Check Browser Developer Tools:
- Open Network tab and filter for
googleadservices.com - Look for conversion requests with your Ads ID and label
- Verify
send_toparameter contains correctAW-XXXXXX/labelformat
- Open Network tab and filter for
- Check Cookies/Storage:
- Look for
[prefix]_googleAds_gtag_calledmarker - Verify marker is set after sync fires
- Look for
- Check Google Ads Dashboard:
- Navigate to Google Ads > Tools & Settings > Conversions
- Check that conversions are being recorded (may take up to 24 hours)
- Server-side Event Validation:
- Use MetaRouter's event debugger
- Verify
context.providers.googleAds.firedis present
Updated about 15 hours ago