Skip to main content
Answer

UTM tracking to full page embed not working

  • March 4, 2023
  • 10 replies
  • 385 views

Forum|alt.badge.img+1

Hi

 

I’ve followed the utm tracking setup tutorials but the utms arent being populated when I look at the results page.

Interestingly, I’ve created a gclid hidden field (to capture the gclid string from google ads) and that is being passed through. 

I’ve got utm tracking switched on in the typeform settings and all 5 utm params switched on

My website is selfemployedmortgagehub.com and the full page typeform embed is at /qualify

Here’s the code I have embeded in webflow

<div data-tf-widget="PFzalDyg"  data-tf-opacity="100" data-tf-inline-on-mobile data-tf-iframe-props="title=DYQ v4" data-tf-transitive-search-params="utm_source, utm_medium, utm_campaign, utm_term, utm_content, gclid" data-tf-auto-focus data-tf-medium="snippet" data-tf-full-screen data-tf-hidden="utm_source=xxxxx,utm_medium=,utm_campaign=,utm_term=,utm_content=,gclid="></div><script src="//embed.typeform.com/next/embed.js"></script>

Can’t see anything obvious that I’m doing wrong, any ideas? Thank you.

Graham

Best answer by mathio-tf

Hello @Graham Cox 

if you want to use transitive-search-params attribute you need to populate those values in the URL of the page with your typeform as well. 

When I click the Get Started button on your website I get redirected here:

https://www.selfemployedmortgagehub.com/qualify

You need to pass variables in query string for this to work, eg:

https://www.selfemployedmortgagehub.com/qualify?utm_source=my_source&utm_medium=my_medium&utm_campaign=my_campaign&utm_term=my_term&utm_content=my_content&gclid=my_gclid

 

10 replies

Forum|alt.badge.img+1
  • Author
  • Sharing wisdom
  • March 4, 2023

I’ve also tried it with data-tf-hidden deleted and still only gclid is passed through

 

<div data-tf-widget="PFzalDyg"  data-tf-opacity="100" data-tf-inline-on-mobile data-tf-iframe-props="title=DYQ v4" data-tf-transitive-search-params="utm_source,utm_medium,utm_campaign,utm_term,utm_content,gclid" data-tf-auto-focus data-tf-medium="snippet" data-tf-full-screen ></div><script src="//embed.typeform.com/next/embed.js"></script>

 


Forum|alt.badge.img+1
  • Author
  • Sharing wisdom
  • March 4, 2023

A further update, I’ve also just disconnected from universal analytics in typeform connect and set up the integration to use GA4. But still no utm data.

 

When I click through from the homepage where I’ve manually added data for the utms like so:

https://www.selfemployedmortgagehub.com?utm_source=facebook&utm_medium=social&gclid=123456789abcdef

 

the url is mangled like so:

 

https://www.selfemployedmortgagehub.com/qualify?_gl=1*3uuvnd*_up*MQ..&gclid=789456abc

 

Any ideas?  

 

Thank you.


Liz
Ex–Typefomer
Forum|alt.badge.img+5
  • Tech Community Advocate
  • March 10, 2023

Hi @Graham Cox Apologies for missing this. 

@mathio do you happen to know if hidden fields are any different with GA4?


mathio-tf
Typeform
Forum|alt.badge.img+5
  • Typeform
  • Answer
  • March 13, 2023

Hello @Graham Cox 

if you want to use transitive-search-params attribute you need to populate those values in the URL of the page with your typeform as well. 

When I click the Get Started button on your website I get redirected here:

https://www.selfemployedmortgagehub.com/qualify

You need to pass variables in query string for this to work, eg:

https://www.selfemployedmortgagehub.com/qualify?utm_source=my_source&utm_medium=my_medium&utm_campaign=my_campaign&utm_term=my_term&utm_content=my_content&gclid=my_gclid

 


Forum|alt.badge.img+1
  • Author
  • Sharing wisdom
  • March 13, 2023

Hi @mathio 

 

Thanks for your reply, I appreciate your help.  That makes sense. The only thing I’m unsure of is how I dynamically grab the utm values to insert them in the button link?

 

Kind regards,

 

Graham


Forum|alt.badge.img+1
  • Author
  • Sharing wisdom
  • March 13, 2023

Hi @Graham Cox Apologies for missing this. 

@mathio do you happen to know if hidden fields are any different with GA4?

No problem, thanks for referring onto Mathio


mathio-tf
Typeform
Forum|alt.badge.img+5
  • Typeform
  • March 13, 2023

The only thing I’m unsure of is how I dynamically grab the utm values to insert them in the button link?

This depends on what tools and languages you use to build your website.

Eg. in PHP you read it from $_GET, in JavaScript you can look at window.location object (or request object server-side).

If you use a CMS to build your website the approach will vary - eg. for Wordpress you need to use a URL Params plugin:
https://wordpress.org/plugins/url-params/


Forum|alt.badge.img+1
  • Author
  • Sharing wisdom
  • March 13, 2023

Thanks @mathio 

 

I’m using webflow, so I’ll post on their community forum and see if there’s a script to grab the values.

 

Thank you for all your help, it’s much appreciated.

 

Graham


Liz
Ex–Typefomer
Forum|alt.badge.img+5
  • Tech Community Advocate
  • March 13, 2023

Let us know what they end up saying, @Graham Cox !


Forum|alt.badge.img+1
  • Navigating the Land
  • November 26, 2025

How did you go over on the Webflow community? Did you find a code snippet to dynamically insert the values?

One potential issue I see with this approach is that you’re just pulling the UTMs from the URL, which means they need to still be present in the URL when the form is submitted.

So if someone clicks one of your ads, lands on your homepage (with UTM's in the URL) and then navigates over to the Contact Us page and completes a form there, the UTM's will no longer be in the URL, so they won't be captured.

To solve this, you would need to grab them from the URL when the visitor lands on your site, store them in a cookie, and then pass them through with form submission.

If needed, there are tools that can handle this for you (Attributer.io, source looper, etc). You basically add hidden fields to the forms and they do the rest (storing the data, writing it into hidden fields, etc). They’ll also send through information on leads that come from organic channels (Organic Search, Organic Social, etc) which is useful. Plus you get to outsource all the support and maintenance to them :)

Source: I am the founder of Attributer.io, and I see heaps of people get stuck on the whole ‘you need to store them rather than just pulling them from the URL’ thing.