Objective
Track how far users scroll on a page (e.g. 25%, 50%, 75%, 90%) and send that data as scroll events to Google Analytics 4, using Google Tag Manager.
Step 1: Enable Scroll Variables in GTM
- Go to Google Tag Manager
- Click Variables in the left menu
- Click “Configure” (top right)
- Under the Scroll section, enable:
✅ Scroll Depth Threshold
✅ Scroll Depth Units
✅ Scroll Direction
Step 2: Create a Scroll Trigger
- Go to Triggers → Click “New”
- Name the trigger: Scroll – Depth % Tracking
- Trigger Configuration → Select Trigger Type: Scroll Depth
- Scroll Depth Type:
✅ Vertical Scroll Depth
5. Set thresholds: 25, 50, 75, 90
6. Fire this trigger on:
✅ All Pages (or choose specific ones if needed)
7. Click Save
Step 3: Create GA4 Event Tag for Scroll
- Go to Tags → Click New
- Name it: GA4 – scroll_depth
- Choose Tag Type → Google Analytics: GA4 Event
- Under Configuration Tag, select your existing GA4 config
- Event Name: scroll_depth
- Add Event Parameters:
Parameter Name Value
scroll_percentage {{Scroll Depth Threshold}}
scroll_direction {{Scroll Direction}}
page_path {{Page Path}}
7. Scroll to Triggering → Select the trigger: Scroll – Depth % Tracking
8. Click Save
Step 4: Preview and Test
- Click Preview in GTM
- Enter your website URL → Connect
- On your website:
- Scroll down slowly
- Observe events in Tag Assistant
4. Confirm that:
- A scroll event appears when you reach 25%, 50%, 75%, or 90%
- The GA4 event fires correctly
- Parameters like scroll_percentage are sent
Step 5: Publish Your Tag
- In GTM, click Submit → Publish
- Name your version: GA4 Scroll Depth Tracking – v1
Note
- You can track horizontal scrolling too — just enable it in the trigger.
- Combine with Page Title, Page Type, or Device Category for richer GA4 reporting.
- Want cleaner naming? Use a Lookup Table to convert 25 → 25%, etc.