How do I set up contact form tracking?

Method 1: The “Thank You” Page (The Gold Standard)

The most robust way to track a form submission is to redirect the user to a dedicated “Thank You” page (e.g., example.com/thank-you) immediately after they click submit.

  • Create the Page: Build a simple page that says “Thanks for contacting us.” Ensure this page is noindex so people don’t find it via Google search (which would skew your data).
  • Redirect: Configure your form plugin (like WPForms or Contact Form 7) to redirect to this URL upon success.
  • Track in GA4:
    • Go to Admin > Events > Create Event.
How do I set up contact form tracking?
  • Custom Event Name: generate_lead (This is a standard Google event name).
  • Matching Conditions: event_name equals page_view AND page_location contains /thank-you.
  • Mark as Conversion: Go to the “Conversions” tab and toggle the switch for generate_lead to “On”.

Method 2: Google Tag Manager (For AJAX Forms)

Modern forms often show a “Success!” message on the same screen without reloading the page (AJAX). To track this, you need a “listener” that detects the specific form submission code.

  • Enable Variables: In GTM, go to Variables > Configure and tick all boxes under “Forms” (Form ID, Form Classes, etc.).
How do I set up contact form tracking? Step 1.1
  • Create Trigger:
How do I set up contact form tracking? Step 1.2
  • Go to Triggers > New > Form Submission.
  • Select “Check Validation” (to ensure empty forms aren’t counted).
  • Fire On: Form ID equals [Your Form ID] (Inspect the HTML of your form to find this, e.g., wp-form-102).
  • Create Tag:
    • Tag Type: GA4 Event.
    • Event Name: form_submit.
    • Trigger: Select the trigger you just created.

Method 3: GA4 “Enhanced Measurement” (The Automatic Way)

Google Analytics 4 has a built-in feature that attempts to track forms automatically. While convenient, it can be inaccurate (often tracking people who start filling a form but abandon it).

How do I set up contact form tracking? Step 2
  • Navigate: Go to Admin > Data Streams.
  • Select Stream: Click on your website URL.
  • Enhanced Measurement: Ensure the toggle is On
How do I set up contact form tracking? Step 2.1
  • Settings: Click the “Gear” icon and ensure Form interactions is checked.
    • Warning: This tracks form_start (user clicks a field) and form_submit. You must ensure you are reporting on form_submit, not just interactions.


Validating Your Tracking (DebugView)

You must verify that the tracking works before trusting the data.

  • GTM Preview: If using Tag Manager, click “Preview,” enter your website URL, and submit a test form. You should see the “Form Submit” tag fire in the debug window.
  • GA4 DebugView:
    • Go to Admin > DebugView.
    • Submit a form on your live site.
    • Watch the timeline. You should see a blue dot appear for generate_lead or form_submit. If you see it, your tracking is live.
Last Updated 2nd February 2026.

Was this article helpful?

We publish our Knowledge Base to help individuals and businesses resolve common issues across websites, advertising platforms, Salesforce and other digital systems.

We regularly review and update our guides, but the platforms, software and services covered can change without notice. As a result, screenshots, settings, features or recommended processes may differ from those available when an article was last reviewed.

The information provided is general guidance and should not be treated as advice specific to your systems or circumstances. UTDS Optimal Choice cannot accept responsibility for errors, data loss, service disruption or other issues resulting from changes made by following these guides.

If you are unsure about any of the steps, particularly where a change could affect live systems, data, tracking or business processes, we recommend speaking to us before making the change. Our team can review your specific setup and provide advice based on the current platform and configuration.

Time for some professional support?

Our team area ready to help. As one of the few digital agencies that is a registered Salesforce Consulting Partner and Google Partner Agency, UTDS Optimal Choice is expertly positioned to support you across your entire digital landscape.