Form tracking means recording, reliably, when a visitor sees a form, starts it, finishes it and becomes a lead, and tying each lead back to where it came from. In practice that is a handful of events pushed into the dataLayer, sent to GA4 through Google Tag Manager, with one of them marked as a key event, and a weekly check that the GA4 count matches the leads in your CRM.
The setup is not hard. What makes form tracking untrustworthy is the detail: lead events fired on button clicks instead of server acceptance, thank-you pages counted twice, consent ignored, spam counted as leads, and ad blockers silently dropping requests. Each one makes the numbers drift away from reality until nobody believes them.
This guide gives you a setup you can build in an afternoon and the checks that keep it honest.
The events to track
Track four steps for every lead form, with consistent names across the site:
| Step | Event name | When it fires | Key event? |
|---|---|---|---|
| View | form_view |
The form is rendered on screen | No |
| Start | form_start |
First interaction with a field or answer | No |
| Complete | form_complete |
Last question answered or result shown | No |
| Lead | generate_lead |
Your server accepted the contact details | Yes |
generate_lead is a GA4 recommended event, so GA4 understands it without extra setup, and it accepts value and currency parameters if you assign lead values. GA4 also has recommended events for later stages, such as qualify_lead and close_convert_lead, which you can send from your CRM once a lead progresses.
Add the same parameters to each event: form_id (a stable name like pricing_estimate), form_location (the page type) and, for multi-step forms, step_number (the multi-step form guide shows a step event). Register the ones you report on as custom dimensions in GA4.
Why not use enhanced measurement alone
GA4's enhanced measurement can collect form_start and form_submit automatically. It is a reasonable start, but it can fire on forms you do not care about, such as search and login, it can miss forms that submit through JavaScript without a page load, and it can record a submit even when validation fails. For lead forms, push your own events. If you keep enhanced measurement's form interactions on, name your own events differently (as in the table above) so the two do not mix.
Pushing events through the dataLayer
Your form, or the developer who maintains it, pushes an event into the dataLayer at each step. The lead event belongs in the success handler, after the server responds:
```js window.dataLayer = window.dataLayer || [];
// in the form's success callback, after the server accepted the submission window.dataLayer.push({ event: 'generate_lead', form_id: 'pricing_estimate', form_location: 'pricing', lead_id: 'sub_8f3a2c' // the submission ID your server returned }); ```
In Google Tag Manager:
- Create Data Layer Variables for
form_id,form_locationandlead_id. - Create a Custom Event trigger for
generate_lead(and one each forform_view,form_start,form_complete, or one trigger with a regex matching all four). - Create a GA4 Event tag with the event name set to
{{Event}}and the variables passed as event parameters. - Preview, submit a real test entry, and confirm the event and its parameters in GA4's DebugView.
Then in GA4, under Admin, mark generate_lead as a key event. Leave the other three as ordinary events. Marking every step as a key event makes the key event count meaningless, and if you import key events into an ad platform, it teaches bidding to chase cheap actions. The micro-conversions guide covers which smaller actions are worth tracking and which are worth optimizing for.
A ViralSales check does this part for you. It pushes start, complete and lead events into the site's own GA4 or dataLayer after the site's consent banner, and it counts views, starts, completions and leads itself, so you have a second count to compare against.
Thank-you page versus event tracking
Counting visits to a /thank-you/ page is the older method. It is easy to set up and still common. It also breaks in predictable ways:
- Reloads and bookmarks count the same lead twice.
- Direct visits count leads that never submitted, especially if the page is indexed or linked.
- Forms that submit without a redirect never reach the page at all.
- No form details: every form that shares the page looks the same.
Event tracking from the success handler avoids all four. If you must keep a thank-you page, add noindex, pass the form ID in the URL, and fire the lead event only once per submission ID.
Consent: track what visitors agreed to
If you serve visitors who are covered by consent rules, your analytics tags should wait for the answer. With Google's consent mode, set defaults for analytics_storage, ad_storage, ad_user_data and ad_personalization before any tag loads, and update them when the visitor chooses in your consent banner. In GTM, use consent settings on each tag so it only fires once the required consent is granted.
Expect your GA4 lead count to sit below your CRM count as a result. That gap is the consent banner doing its job. Measure it once so you know its normal size.
Matching form submissions to the CRM
GA4 tells you how many leads came from which source. Your CRM tells you which leads became revenue. Connect them:
- Generate a submission ID on your server and send it both to the CRM record and as
lead_idon the GA4 event. - Store the source on the lead. Capture UTM values, the landing page and click IDs such as
gclidinto hidden form fields, so the CRM record carries them. The UTM parameters guide covers naming them consistently. - Compare weekly. Count
generate_leadin GA4 per form and new CRM records per form for the same week. Write down the normal gap. A sudden change means something broke.
If your forms and CRM need proper integration work, DevriX builds CRM and form integrations.
Filtering spam before it becomes a lead
Spam inflates both GA4 and the CRM. Stop it at the server, then fire the lead event only for accepted submissions:
- A hidden honeypot field that people never fill in.
- A minimum time between page load and submit.
- Server-side validation of email format and domain.
- A rule to drop submissions with links in the name field.
Also filter your own team. In GA4, define internal traffic by IP and turn the data filter on, and mark test submissions with an email pattern your CRM can exclude.
Why ad blockers drop form requests
Ad blockers and privacy extensions decide what to block by matching patterns, and many of those patterns are words in request paths. Counted on 16 November 2026 across EasyList and related lists, 1,410 rules match /track, 318 match /events, 292 match /collect, 304 match /pixel and 68 match /popup.
Two consequences. First, analytics requests are blocked for some visitors, so GA4 will always undercount; your CRM is the closer count of real leads. Second, and worse, your own form endpoint can be caught. A form tool or custom handler that posts to /track-lead or /events/submit may fail outright for those visitors, and then the lead itself is gone along with the measurement. Name your form endpoints plainly (/api/contact, /forms/quote) and test every form from a browser with a blocker installed. Failed requests like these look exactly like visitors giving up, which the form abandonment guide covers.
None of this is about overriding a visitor's choice. Consent decides whether you measure someone. Path naming decides whether a lead who wanted to reach you can.
For WordPress sites, scheduled checks from WP Commit can confirm your tracking tags still load after theme and plugin updates.
Where to start
- Pick your main lead form and push
form_view,form_start,form_completeandgenerate_leadinto the dataLayer, with the lead event in the server success handler. - Set up the GTM triggers and GA4 tag, mark only
generate_leadas a key event, and confirm it in DebugView with a real test entry, including one from a browser with an ad blocker. - Add a submission ID and hidden source fields, then compare GA4 leads with CRM records every week and write down the normal gap.