Solved

Unable to See Klaviyo Form Submissions Events in Google Analytics / Shopify

  • 2 September 2022
  • 1 reply
  • 32 views

Badge

Hello,

we run a Shopify shop with native integration with Google Analytics. 

I added the script for tracking Klaviyo events in theme.liquid as follows:

<script>
window.addEventListener("klaviyoForms", function(e) {
if (e.detail.type == 'open' || e.detail.type == 'embedOpen') {
ga('send', 'event', 'Klaviyo form', 'form_open', e.detail.formId, {nonInteraction: true});
}
if (e.detail.type == 'submit') {
ga('send', 'event', 'Klaviyo form', 'form_submit', e.detail.formId);
}
if (e.detail.type == 'close') {
ga('send', 'event', 'Klaviyo form', 'form_close', e.detail.formId, , {nonInteraction: true});
}
});
</script>

When I try to test whether the events are coming through via Google Analytics Real time Events, I see nothing coming from Klaviyo.

I can’t figure out whether something is blocking the event send. 

Context: 

  • Shopify (non plus) 
  • in theme.liquid:
    • Segment script
    • GTM script 
    • Clarity script

Anyone could possibly point out a direction to solve the issue? 

Thanks

icon

Best answer by Omar 3 September 2022, 15:24

View original

1 reply

Userlevel 6
Badge +30

Hi @VincenzoGTJ,

Without knowing your site or setup you might want to check if you're using gtag version of the tracking. Check this page for the 2 versions: https://help.klaviyo.com/hc/en-us/articles/115005077027-How-to-Configure-Google-Analytics-Goal-Tracking-for-a-Signup-Form#:~:text=You%20can%20track%20Klaviyo%20forms,the%20snippet%20into%20your%20theme

 

Also when testing this make sure you're using a Google Analytics views without any ip filters. If you're filtering yourself out you won't see your events.

 

Hope it helps

Omar Lovert // Polaris Growth // Klaviyo Master Gold Partner

Reply