GA4, Tag Manager, and conversion events to see where each lead comes from

Set up GA4, Tag Manager, and conversion events to know which channel each lead comes from, bring that source into your CRM, and calculate cost per lead.

AntonnyTracking7 min read

Key takeaways

  • Without conversion events set up, GA4 shows visits but doesn't tell you which channels bring in leads.
  • With Tag Manager, you can track form submissions, WhatsApp clicks, and bookings without touching the website code for every change.
  • Standardized UTMs and hidden form fields carry each lead's source all the way to the CRM.
  • With the source in the CRM, you can calculate the cost per lead for each channel and see which leads turn into sales.

To know where your leads come from, the website needs to record every conversion and store the source of whoever converted. You can solve this with Google Analytics 4 (GA4), Google Tag Manager, UTMs on campaign links, and a few fields in the CRM.

With everything in place, you can see which channel brings in the most leads and how much each one costs. And because the source reaches the CRM, you can tell which of those leads became customers.

Why doesn't GA4 alone show where leads come from?

With the default setup, GA4 records visits and some automatic interactions, such as scrolls and outbound link clicks. It knows where each visit came from, but it doesn't know what counts as a lead for your business.

GA4's enhanced measurement does try to record form submissions, but it can fail with forms that don't reload the page or that open inside an iframe. That's why conversions are usually set up in Google Tag Manager, a container installed once on the website. In it, you define what to send to GA4 and when, without touching the website code for every change.

Which conversion events should you set up in Tag Manager?

For education, software, and services companies, three events usually cover the essentials.

The first is the form submission. The event should fire when the form is accepted, not on the button click, which also counts people who missed a required field. Use the thank-you page or the success message as the signal. For this event, GA4 recommends the name generate_lead.

The second is the WhatsApp click, captured by a click trigger on links containing wa.me or api.whatsapp.com. This measures intent: the click opens the app, but it doesn't guarantee the person sent a message.

The third is the booking. If the scheduler is on your website, use the confirmation page. If it's an external tool, check whether it notifies the page when the time slot is confirmed; Tag Manager can listen for that notification.

Before publishing, test in Tag Manager's Preview mode and check in GA4's DebugView that each event arrives only once. Then mark all three as key events, the name GA4 now uses for conversions.

How do you use UTMs without messing up your reports?

UTMs are parameters at the end of a link that tell GA4 where a visit came from. The essentials are utm_source (the source, such as instagram), utm_medium (the type of media, such as cpc or email), and utm_campaign (the campaign). Meanwhile, utm_content and utm_term help separate ads, audiences, or keywords.

The problem is usually a lack of consistency. Four rules prevent the mess:

  • Everything in lowercase. To GA4, "Instagram" and "instagram" are different sources.
  • A single dictionary, in a team spreadsheet, so no one writes ig where someone else writes instagram.
  • In utm_medium, only values GA4 recognizes, such as cpc and email.
  • No UTMs on the website's internal links, because they replace the visit's true source.

In Google Ads, auto-tagging (gclid) passes the source to GA4 when the accounts are linked. In Meta Ads, the URL parameters field accepts dynamic parameters that fill in the campaign and ad names.

How do you keep a lead's source when it goes to the CRM?

GA4 shows aggregate numbers and doesn't tell you who each lead is, in part because Google Analytics policies prohibit sending personal data like names and email addresses. The link between person and source happens in the CRM. The most common approach:

  1. Create hidden fields on the form for the UTMs, the landing page, and click identifiers like gclid and fbclid.
  2. Store those values in a cookie on the first visit, so the source isn't lost if the person only converts days later. If you can, also store the last source before the conversion.
  3. Map each hidden field to a custom field in the CRM, whether it's RD Station, HubSpot, Pipedrive, or another.
  4. Test with a real campaign link and check that the lead reached the CRM with the source filled in.

WhatsApp is the most common blind spot, because people who click and chat directly never go through a form. A simple fix is a pre-filled message with a code for each page or campaign, like "Hi! I came from the website (LP-ADS)", which the agent or an automation logs in the CRM. See also how to get website leads into your CRM and WhatsApp.

How do you calculate the cost per lead for each channel?

The math is the channel's spend divided by the leads it generated in the same period. Spend comes from the ad platforms; leads come from the CRM, filtered by source.

Judging by cost per lead, Meta Ads looks like the best channel. CRM data can flip that reading. In the same example, suppose 30 of the 100 Google Ads leads became sales opportunities, compared with 16 of the 160 from Meta Ads. Cost per opportunity comes to R$400 on Google Ads (R$12,000 ÷ 30) and R$615 on Meta Ads (R$9,840 ÷ 16).

That's why you should track cost per lead alongside cost per opportunity and, when possible, cost per sale. For organic channels, use production cost instead of media cost.

Where does Microsoft Clarity fit in?

GA4 tells you what happened. Microsoft Clarity shows how it happened, with click and scroll heatmaps and session recordings in which sensitive fields are masked. You can see where people stop reading and at what point in the form they give up.

It also flags signs of frustration, like repeated clicks in the same spot, and lets you filter recordings by them. If GA4 shows a page with lots of visits and few conversions, the recordings help you find out why, such as a button that doesn't work on mobile.

Since Clarity and GA4 use cookies, include both in the website's privacy policy and cookie notice.

Frequently asked questions

Do I need Tag Manager if GA4 is already installed?

It's not required, but it helps. Without it, every new event depends on a change to the website code. With it, events, ad pixels, and Clarity live in one place, and you can test before publishing.

What's the difference between an event and a conversion in GA4?

Every interaction recorded in GA4 is an event. A conversion is an event you mark as important to the business, and the interface now calls it a key event. Viewing the pricing page is an event; submitting the quote request form is a key event.

Why don't GA4 numbers match the CRM's?

Because they'll never match exactly. Visitors with ad blockers or who decline cookies may be left out of GA4, and people who switch devices along the way can be counted twice. Use the CRM as your reference for the number of leads, and GA4 to understand source and trends.

Where to start measuring

Start with the three conversion events and check that each one fires only once. Then build the UTM dictionary and add the hidden fields to the form. With a month of clean data, the cost-per-lead-by-channel spreadsheet will already show where your spend pays off and where it only generates volume.

This is the tracking work Anzen does: Analytics, Tag Manager, and conversion events set up, with heatmaps and recordings in Microsoft Clarity. For a read on your case, the free 30-minute assessment looks at positioning, funnel, and channels, with no sales pitch. Just book it through the contact page.

Antonny

AntonnyFounder of Anzen

He founded Anzen after years of designing websites, sales pages, and funnels for schools, product launches, and service businesses. He leads the strategy on projects and writes about what he learns from them.

About Anzen

Start with a free assessment.

In 30 minutes, we look at your positioning, your funnel, and your channels, and tell you what we'd change first.
No sales pitch.