Skip to content
← Marketing, SEO/AEO/GEO & Measurement

Draft — in editorial review, not yet published. Content has not been approved by a human reviewer.

Lesson 36 / 50 · Version 2.2.0

GA4 and Google Tag Manager

Level
Beginner–Intermediate
Duration
15 min learn + 15 min apply
Prerequisites:
None

Why it matters: If you can't say which visits produce inquiries, every marketing decision is a guess. A short measurement plan plus correct tagging is the base for ads, SEO, and reporting.

By the end you can:

  • Define events, parameters, and key events
  • Write a measurement plan
  • Explain GTM tags, triggers, and variables
  • Test and respect consent

Learn (15 min)

1. Events describe interactions (5 min)

GA4 records interactions as events (page_view, generate_lead, purchase), each with optional parameters. Mark a key event only when it represents a real business outcome. Not every click is a success.

Event: generate_lead
Parameters: form_name = "team_headshots", service_type = "corporate", value = 0

Don't send personal data (names, emails, phone numbers) in parameters.

2. Tag Manager deploys tags (5 min)

Google Tag Manager (GTM) manages tags (what to send), triggers (when), and variables (values). A common pattern is for your site to push to the data layer and GTM to react:

window.dataLayer = window.dataLayer || [];
dataLayer.push({ event: 'quote_request', service_type: 'corporate' });

GTM trigger: Custom Event = quote_request → Tag: GA4 Event generate_lead with parameter service_type ← Data Layer Variable. Use one implementation pattern; don't install the Google tag both in code and in GTM without a plan, or you'll double count.

3. Test and honor consent (5 min)

Use GTM Preview and GA4 DebugView/Realtime to confirm event name, parameters, timing, and that a lead counts once. Handle internal traffic. Consent tools must communicate users' choices before tags act as configured, and the tool does not decide what your legal obligations are, so follow applicable privacy requirements and your counsel's guidance.

Apply (15 min)

Worked example (3 min). Measurement plan for quote requests.

ItemDecision
Business questionWhich channels produce quote requests?
Eventgenerate_lead (key event)
TriggerSuccessful form submission (thank-you state), once per submission
Parametersservice_type, form_name
TestSubmit in Preview mode; confirm one event in DebugView
Declined consentFollow consent configuration; don't fire restricted tags

Lab (7 min): Plan three events.

  1. List the three most valuable actions on your site (quote request, call click, booking).
  2. For each, write the event name, trigger, parameters, and whether it's a key event.
  3. Write the test steps and the expected result in DebugView.

Deliverable: A three-row measurement plan. You're done when: Each event answers a business question and has a once-only rule.

Check yourself (5 min)

  1. What is a GA4 event?
  2. What is a key event?
  3. What does a GTM trigger do?
  4. Scenario: Leads in GA4 are exactly double the CRM count. What do you check?
  5. Does GTM decide legal consent requirements?

Reference

Common mistakes

SymptomLikely causeFix
Doubled eventsDuplicate tags (code + GTM)Choose one method
Fires on page loadTrigger tied to page viewFire on the success event
PII in parametersCareless mappingRemove personal data

Cheat sheet: Business outcome → event name → trigger and parameters → test → verify in GA4 → respect consent.

Key terms: event, parameter, key event, tag, trigger, variable, data layer.

Interview prompts: How would you track a form submission accurately?

Go deeper: GA4 events · Key events · GA4 setup in GTM · Tag Manager consent

Next: Lesson 37 — paid search.