Set up a form submission event in Google Analytics 4
Last Updated / Reviewed: Jan 10th, 2023
Execution Time: ~5 Mins
Goal: Set up a form submission event in Google Analytics 4 via Google Tag Manager.
Ideal Outcome: You’re successfully tracking form submissions on your site.
Prerequisites or requirements: You need to have edit access to Google Analytics 4 and Google Tag Manager account.
Why this is important: Tracking form submission events on your site allows you to create conversion goals around for lead generation, newsletter sign up and more.
Where this is done: Google Analytics 4 and Google Tag Manager.
When this is done: After you’ve set up Google Analytics 4 on your site.
Who does this: The person responsible for web analytics.
Set up a new form submission event in Google Tag Manager
- Sign in to your Google Tag Manager account.
- Select the container that is set up on your website.
- Click “New Tag”.
- In this SOP we will fire an event when a user submits a form on our site, so we will name this tag “Form Submission”. Then click on the Tag Configuration icon.
- Select “Google Analytics: GA4 Event” from the list of tag types.
-
Next, select the Google Analytics 4 configuration tag and name this event, then click “Save”. This event name will appear (and be used) in Google Analytics so it should help you identify which form the user is submitting. If you have multiple forms, it’s recommended that you use a unique event name to help you identify them.
For example: “form_submission_leadmagnet_a”, “form_submission_leadmagnet_b”Note: If you can’t find any Google Analytics 4 configuration tag, then you have not added Google Analytics 4 via Google Tag Manager. Follow this SOP to set up Google Analytics 4 via Google Tag Manager on your site.
- You’ll see a “No Triggers Selected” pop up, click “Add trigger”.
-
Adding a trigger informs Google Tag Manager when it should fire this event. Since this is a form submission event, it should fire when someone submits a form. Select Form Submission from the list of triggers.
Important: Google’s Form Submission Trigger only works for standard submit events. If you’re using a custom form solution, be sure to check with your developer or email marketing platform’s official documentation.
- Next, select “Form Submission” to edit its settings.
- Click “Page URL” to edit the URL where your form is located.
- Make sure the URL is the correct URL. When a user submits a form on this page, you want to trigger the event “form_submission” and send it to Google Analytics. Once done, click “Save”.
- Once you’re done with the tag and trigger configuration, click “Save”.
- You should see the new tag in the dashboard. Click “Submit”.
- Add a name and description to this Google Tag Manager changes and click “Publish”.
- Next, head to Google Analytics and set up this form submission event as a conversion goal.
Set up new form submission as conversion goal in Google Analytics 4
- Login to your Google Analytics account.
- Make sure you’ve selected the right property (the website that you’ve implemented the Google Analytics 4 tracking code).
- Click the “Configure” tab then select “Conversions”.
Click the “Configure” tab then select “Conversions”. - Name this conversion event. It should be the same name as the one you set up in Google Tag Manager earlier. Then click “Save”.
- You should then see the new conversion event listed in the conversion events list.
- After you’ve set this up. It may take up to 24 hours for the event to show, provided that there are users signing up on the page.
- While you wait, you can then proceed to verify if the form submission event is set up correctly.
Verifying Form Submission Event is set up correctly
- Sign in to your Google Tag Manager account.
- Click “Preview”. This will activate Google Tag Manager’s Preview and Debug mode.
- A new window (Tag Assistant) will launch. Add the URL of your website where the Google Tag Manager and the custom event was implemented and click “Connect”.
- A new tab will open with your website loaded. You will also see a confirmation message that the Tag Assistant is connected.
- Back to the previous tab (Tag Manager), and click “Continue”.
- We can now start testing if the form submission event works. Head over to your website where the sign up form is located. This should be the same page that you defined in step 11 of “Set up a new custom event in Google Tag Manager”.
- Submit the form that you want to track.
- Back in the Tag Assistant tab, you should see the list of events triggered on the sidebar. If you see the “Form submission” event that you set up earlier, then that confirms that the form submission event is firing correctly.
- Now that you’ve verified the form submission is set up correctly. All you need to do is wait for the event to show up in Google Analytics.
- Login to your Google Analytics account.
- Click “Configure”.
- Make sure you’re in the conversion tab, and check for the Form submission event that you set up.
- If you see the event, that means you’ve successfully set it up!