Google Ads Conversions
Learn how to integrate Google Ads conversion tracking with Hardal using server-side Google Tag Manager
Adding Google Ads Conversion Tracking to Hardal
Overview
This guide walks you through integrating Google Ads conversion tracking with Hardal analytics using Google Tag Manager (GTM). By leveraging Hardal’s server-side tracking capabilities, you can improve data accuracy, bypass ad blockers, and enhance website performance while maintaining reliable conversion tracking for your Google Ads campaigns.
This integration uses server-side tracking, which helps preserve user privacy while improving data reliability compared to traditional client-side implementations.
Prerequisites
Before you begin, ensure you have:
- An active Hardal account with the tracking script installed on your website
- Admin access to Google Tag Manager
- Admin access to Google Ads
- A Google Tag Manager web container set up
- A Google Ads conversion action created
- Basic understanding of Google Tag Manager concepts
Setting up a custom domain is strongly recommended for better data ownership and reliability. See the Custom Domain Setup Guide for instructions.
Configuring Client-Side Tag Manager
Step 1: Set up the Conversion Linker Tag
The Conversion Linker tag helps capture click information that can be used for conversion tracking.
Create Conversion Linker Tag
- In your web container, go to “Tags” and click “New”
- Choose “Conversion Linker” as the tag type
- Configure it to fire on “All Pages”
- Name the tag (e.g., “Conversion Linker”) and save it
Step 2: Configure Google Analytics 4 for Key Events
If you’re tracking conversions through GA4 events:
Set up Event in GA4
- In Google Analytics 4, go to Admin > Property Settings > Custom Definitions
- Click “Create Custom Event” and add your conversion event
- Navigate to Admin > Property Settings > Key Events
- Add your conversion event as a key event
- Save your changes
Step 3: Create GA4 Event Tags for Conversions
Create GA4 Event Tag
- In your web container, go to “Tags” and click “New”
- Choose “Google Analytics: GA4 Event” as the tag type
- Select your GA4 Configuration tag
- Enter the event name (e.g., “purchase”, “sign_up”, etc.)
- Add any required parameters (like value, currency, etc.)
- Set appropriate triggers for when the conversion occurs
- Name and save the tag
Configuring Server-Side Tag Manager
Step 1: Create the GA4 Client
Add GA4 Client
- In your server container, go to “Clients” and click “New”
- Choose “Google Analytics: GA4” as the client type
- Name the client (e.g., “GA4 Client”) and save it
Step 2: Set up the Conversion Linker Tag
Create Server-Side Conversion Linker
- In your server container, go to “Tags” and click “New”
- Choose “Conversion Linker” as the tag type
- Configure it to fire on “All Pages”
- Name the tag (e.g., “Conversion Linker”) and save it
Step 3: Create Google Ads Conversion Tracking Tag
Set Up Ads Conversion Tag
- In your server container, go to “Tags” and click “New”
- Select “Google Ads Conversion Tracking” as the tag type
- Enter your Conversion ID and Conversion Label from Google Ads
- Under “Triggering”, create a new trigger:
- Select “Custom Event” trigger type
- Enter the same event name as configured in your GA4 Event tag
- If needed, add conditions to filter specific conversions
- Name the tag (e.g., “Google Ads - Purchase Conversion”) and save it
For ecommerce tracking, the Google Ads Conversion Tracking tag automatically reads transaction ID, conversion value, and currency code from the corresponding ecommerce fields in the GA4 event.
Setting Up Enhanced Conversions (Optional)
Enhanced Conversions improve match rates by using hashed customer data. To implement:
Step 1: Create a User-Provided Data Variable in Web Container
Add User-Provided Data Variable
- In your web container, go to “Variables” and click “New”
- Select “User-Provided Data” as the variable type
- Choose one of these collection methods:
- Automatic collection: Easiest but least control
- Manual configuration: Specify CSS selectors for form fields
- Code configuration: Most control, uses your custom JavaScript
- Name the variable (e.g., “Enhanced Conversion Data”) and save it
Step 2: Add User Data to Your GA4 Configuration Tag
Update GA4 Configuration
- Edit your GA4 Configuration tag
- Under “Fields to Set”, add a new field:
- Field Name:
user_data
- Value: Select your User-Provided Data variable
- Field Name:
- Save the tag
Step 3: Enable Enhanced Conversions in Server-Side Tag
Enable Enhanced Conversions
- In your server container, edit your Google Ads Conversion Tracking tag
- Enable the Enhanced Conversions option
- Save the tag
Setting Custom Conversion Values (Optional)
If you need to use custom values for your conversions:
Create a Variable for Custom Value
- In your server container, go to “Variables” and click “New”
- Create a variable that returns your desired conversion value
- Name the variable (e.g., “Custom Conversion Value”) and save it
Configure Conversion Value in Tag
- Edit your Google Ads Conversion Tracking tag
- In the “Conversion Value” field, select your custom variable
- Specify the “Currency Code” if needed
- Save the tag
Validation and Troubleshooting
To verify your setup is working correctly:
Test with Preview Mode
- Enable Preview mode in your web container
- Enable Preview mode in your server container
- Load your website and perform a test conversion
- Verify the event is being received by the server container
- Confirm the Google Ads Conversion Tracking tag is firing
Common Issues
Best Practices
Performance Optimization
- Remove any redundant client-side Google Ads tags to avoid duplication
- Use the server container to consolidate multiple conversion tags
- Leverage Hardal’s batching capabilities for multiple events
Secure Implementation
- Always use HTTPS for your Hardal endpoints
- Set up a custom domain for first-party data collection
- Ensure proper PII handling with Enhanced Conversions
Maintenance
- Regularly check your server container logs for errors
- Update your conversion tracking setup when making changes to your website
- Monitor conversion discrepancies between Google Ads and your internal systems