If you’re running an osCommerce store, GA4 audience integration with Google Ads is a powerful way to retarget users based on behavior, such as viewing a product, abandoning the cart, or completing a purchase. This setup allows you to use rich event-based audiences in GA4 to fuel high-precision remarketing campaigns in Google Adsβwithout needing custom pixels.
π― Why Link GA4 Audiences to Google Ads?
- Run audience-based Google Ads campaigns without managing multiple tags
- Use cross-platform user signals (e.g., mobile, desktop, engaged sessions)
- Unlock Predictive Audiences like βlikely to purchase in 7 daysβ
- Retarget users who performed specific ecommerce actions (product view, add to cart, etc.)
β Prerequisites
- Google Analytics 4 property set up
- Google Ads account with Admin access
- GA4 properly implemented in osCommerce via GTM
- Audience definition strategy ready (e.g., viewed product but no purchase)
π¦ Step 1: Link GA4 with Google Ads
- Go to GA4 β Admin β Product Links
- Select Google Ads β Link
- Click “Choose Google Ads accounts” β Select your Ads account
- Enable “Enable Personalized Advertising”
- Optionally check: Auto-tagging and Audience sharing
- Click Next β Then Submit
π οΈ Step 2: Verify Ecommerce Events Are Flowing in GA4
For proper audience segmentation, ensure the following events are firing:
GA4 Event | Triggered On |
---|---|
view_item |
Product detail page (product_info.php ) |
add_to_cart |
Add to cart action |
begin_checkout |
Checkout start |
purchase |
Order success page (checkout_success.php ) |
You should already be pushing these events via GTM or direct dataLayer.push()
calls. Example:
dataLayer.push({
event: 'view_item',
ecommerce: {
items: [{
item_id: 'SKU123',
item_name: 'T-Shirt',
price: 29.99
}]
}
});
GTM should have GA4 Event Tags with the same names firing based on custom event triggers.
π§© Step 3: Create Audiences in GA4
Go to: GA4 β Admin β Audiences β New Audience
β Example 1: Product Viewers (No Purchase)
Conditions:
event_name
=view_item
- AND
event_name
βpurchase
within 7 days
β Example 2: Abandoned Cart
Sequence:
add_to_cart
occurred- No
purchase
event within 3 days
β Example 3: Engaged Visitors
session_duration
> 60 seconds- AND
event_count
> 3
β Example 4: Buyers
event_name
=purchase
Once saved, these audiences will automatically sync to your linked Google Ads account.
π€ Step 4: Use GA4 Audiences in Google Ads
- Go to Google Ads β Tools & Settings β Audience Manager
- You will see your GA4 audience lists prefixed with:
GA4 - Product Viewers
,GA4 - Abandoned Cart
, etc.
- You can now:
- Add them to Search, Display, YouTube, or Performance Max campaigns
- Use them as observation or targeting segments
π§ͺ Step 5: Test Audience Membership in GA4
To confirm audience membership is working:
- In GA4, go to Configure β Audiences
- Click on the Audience β See βMembershipβ count
- Use GA4 DebugView to simulate events and confirm users qualify
π Optional: Trigger Specific GA4 Events in osCommerce (PHP + JS)
In product_info.php
:
<script>
dataLayer.push({
event: "view_item",
ecommerce: {
items: [{
item_id: "<?= $product['model']; ?>",
item_name: "<?= $product['name']; ?>",
price: <?= $product['price']; ?>
}]
}
});
</script>
Use GTM to create GA4 event tags for these events with the appropriate triggers.
π Privacy and Consent Compliance
If your site serves EU or California users:
- Enable Consent Mode v2 in GTM
- Use a Consent Management Platform (CMP) to gate tracking
- Ensure “Enable Ads Personalization” in GA4 respects consent signals
π Performance-Based Audience Examples
Audience Name | Google Ads Use Case |
---|---|
Product Viewers | Dynamic Remarketing Campaigns |
Cart Abandoners | Display or Search retargeting |
Repeat Visitors (3+ visits) | Bidding strategy for engaged users |
Purchasers | Upsell / Cross-sell campaigns |
β Summary
With GA4 audience integration in Google Ads, osCommerce store owners can now:
- β Retarget based on event-driven, user-level signals
- β Personalize campaigns using dynamic product behavior
- β Leverage predictive audiences (e.g., likely to purchase soon)
- β Manage all tracking centrally via GTM + GA4
π Optional Add-ons
- π Dynamic Remarketing integration via GA4 audiences
- π Link GA4 predictive audiences to Performance Max campaigns
- π§ Server-side GA4 + Ads audience enrichment for enhanced matching