Trainer: Slim LARIBI
Original, up-to-date version on laribislim.com ↗
E-commerce tracking — GTM × GA4 × Google Ads × Meta
The journey of a data point:
from the site
to marketing tools
1 · Page view
2 · Product page
3 · Add to cart
4 · Purchase
▶ Autoplay
Cookies accepted
Pick an event on the right, then follow the data. 💡
Click any block
(site, dataLayer, variable, tag, tool) to see its explanation.
1
🛒
The WooCommerce site
The customer browses and acts
🏠 Home
👕 Product page
🛍️ Add to cart
✅ Thank you for your order
2
🧩
Snippet WPCode
Gets the data out of WordPress
WooCommerce knows:
order, products,
amount, customer…
→ it writes it in the page
3
📮
The dataLayer
The mailbox: dataLayer.push(…)
◆
Google Tag Manager
The conductor: it listens, collects, computes and sends
4
Triggers
All pages
CE - view_item
CE - add_to_cart
CE - purchase
Role
The trigger answers the question
“when?”
: it watches the dataLayer and tells tags to fire.
5
Variables
DLV · read the dataLayer
DLV - ecommerce.value
—
DLV - …currency
—
DLV - …transaction_id
—
DLV - ecommerce.items
—
Customer data · Google Ads / Meta
DLV - user_data.email
—
DLV - user_data.phone
—
UPD - Customer data
—
DLV · remarketing Google Ads
DLV - ecomm_prodid
—
DLV - ecomm_pagetype
—
DLV - ecomm_totalvalue
—
CJS · compute
CJS - VIP customer
—
CJS - Basket segment
—
CJS - Purchase time
—
Constants
CONST - GA4 ID
G-XXXX
CONST - Google Ads ID
AW-123…
6
Tags
GA4 · analyse
GA4
Google tag (config)
GA4
GA4 - Event -
purchase
Google Ads · drive the ads
ADS
Conversion Linker
ADS
Conversion - purchase
ADS
Remarketing
Meta · drive the ads
META
Pixel -
Purchase
7
📊
GA4
waiting
Analyse: where, what, who, when
—
📢
Google Ads
waiting
Optimise bidding, retarget
—
📱
Meta (Facebook / Instagram)
waiting
Optimise campaigns, retarget
—
0
of 7
Ready to follow a purchase?
Click “Next step” to move at your own pace, or “Autoplay” to see the whole journey at once.
Next step ›
↺ Restart
✕
© 2026 Slim LARIBI ·
laribislim.com
— Trainer, CEO WeScaleUp Academy, eCommerce Director
💬 WhatsApp +216 22 354 833