# Creating a google analytics trigger based on a custom form field for form submissions

**URL:** <https://forum.wixstudio.com/t/creating-a-google-analytics-trigger-based-on-a-custom-form-field-for-form-submissions/68332>\
**Category:** Ask the community\
**Tags:** question, wix-editor, wix, code, wix-studio\
**Created:** [February 3, 2025, 6:14pm UTC](https://forum.wixstudio.com/t/creating-a-google-analytics-trigger-based-on-a-custom-form-field-for-form-submissions/68332 "2025-02-03T18:14:10Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Robbie\_Katz](https://sea1.discourse-cdn.com/wix/user_avatar/forum.wixstudio.com/robbie_katz/32/104735_2.png) [@Robbie\_Katz](https://forum.wixstudio.com/u/Robbie_Katz)\
**Post date:** [February 3, 2025, 6:14pm UTC](https://forum.wixstudio.com/t/creating-a-google-analytics-trigger-based-on-a-custom-form-field-for-form-submissions/68332/1 "2025-02-03T18:14:10Z")

</div>

**Question:**  
How do I track custom form dropdown field values as part of a form submission that is passed back to google analytics?

**Product:**  
Wix Editor

**What are you trying to achieve:**  
I have a custom form on my website that tracks email leads who land on our site. We ask leads to indicate their company size in this form using a dropdown. I want to create a conversion event I can optimize towards in google ads that is only recorded when these form submissions have a certain company size.

Right now I can track form submissions, I just can’t pass that company size back as part of the lead/submit\_form events. Let me know what you folks recommend.

Should I create a custom variable in google analytics? Do I need a custom code snippet using the analytics api? I’ve seen a bunch of mixed answers but nothing clear.

**What have you already tried:**  
I’ve tried looking for it in the data layer and am looking into writing a custom javascript listener (My issue is how I map the custom field value to a google analytics field that doesn’t yet exist and whether tracking should be triggered by the tag or by the header code in Wix)

I figure there has to be a simpler way to do this

---

<div class="post-metadata">

**Author:** ![johnscar](https://sea1.discourse-cdn.com/wix/user_avatar/forum.wixstudio.com/johnscar/32/107122_2.png) [@johnscar](https://forum.wixstudio.com/u/johnscar)\
**Post date:** [April 8, 2025, 7:23am UTC](https://forum.wixstudio.com/t/creating-a-google-analytics-trigger-based-on-a-custom-form-field-for-form-submissions/68332/2 "2025-04-08T07:23:36Z")

</div>

I ran into the same issue and got it working by sending the form field data into the data layer first, then using that in a custom GTM trigger. If you’re tracking lots of custom fields or doing this for clients, a [website analytics agency](https://www.atriaanalytics.co.uk) might be able to set up a cleaner solution or help automate it across multiple forms.

---

<div class="post-metadata">

**Author:** ![joodyfleisch](https://avatars.discourse-cdn.com/v4/letter/j/9d8465/32.png) [@joodyfleisch](https://forum.wixstudio.com/u/joodyfleisch)\
**Post date:** [April 10, 2025, 4:32pm UTC](https://forum.wixstudio.com/t/creating-a-google-analytics-trigger-based-on-a-custom-form-field-for-form-submissions/68332/3 "2025-04-10T16:32:33Z")

</div>

did anyone end up successfully pushing custom field data into Google Analytics using Google Tag Manager? I’m trying something similar and wondering if a Data Layer push with a unique event name did the trick for anyone here. Thinking about using GTM’s triggers with form field values—just not sure about the best timing or setup.
