# Track GA event in Piwik using Tally

**URL:** <https://community.piwik.pro/t/track-ga-event-in-piwik-using-tally/1722>\
**Category:** API & integrations\
**Created:** [March 3, 2023, 11:53am UTC](https://community.piwik.pro/t/track-ga-event-in-piwik-using-tally/1722 "2023-03-03T11:53:39Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jeff](https://avatars.discourse-cdn.com/v4/letter/j/e19b73/32.png) [@Jeff](https://community.piwik.pro/u/Jeff)\
**Post date:** [March 3, 2023, 11:53am UTC](https://community.piwik.pro/t/track-ga-event-in-piwik-using-tally/1722/1 "2023-03-03T11:53:39Z")

</div>

Hi,

I am using tally.so and want to track the custom events tally is sending : [Google Analytics integration](https://tally.so/help/google-analytics-integration#717a6d7d5f3048b08556408c75355be8)

Unfortunatly I can’t make it work. I tried a lot of different things (Custom Goals, different Tags, different triggers).

The event I see in the debugger is the following:

```auto
{
  "0": "event",
  "1": "Tally.FormSubmitted",
  "2": {
    "event_category": "/votre-avis-compte",
    "event_label": "Votre avis compte",
    "non_interaction": true
  }
}

```

What do I need to do?

Thank you  
Jeff

---

<div class="post-metadata">

**Author:** ![kuba](https://dub1.discourse-cdn.com/flex005/user_avatar/community.piwik.pro/kuba/32/7_2.png) [@kuba](https://community.piwik.pro/u/kuba)\
**Post date:** [March 3, 2023, 12:08pm UTC](https://community.piwik.pro/t/track-ga-event-in-piwik-using-tally/1722/2 "2023-03-03T12:08:10Z")

</div>

Hi. I’m not really into Tally, but I’d check how did they implement Google Analytics integration on the technical level. All we need to do is capturing all the important event data and forwarding it to Piwik PRO. Do you have any publicly available website where such a form could be tested? Ideally, with Piwik PRO container installed? I’d also need some information on what exactly you want to achieve. I assume it’s all about sending a custom event to Piwik PRO with a few values like category, action or label.

---

<div class="post-metadata">

**Author:** ![Jeff](https://avatars.discourse-cdn.com/v4/letter/j/e19b73/32.png) [@Jeff](https://community.piwik.pro/u/Jeff)\
**Post date:** [March 3, 2023, 12:13pm UTC](https://community.piwik.pro/t/track-ga-event-in-piwik-using-tally/1722/3 "2023-03-03T12:13:17Z")

</div>

Hi,

here is a form with a Piwik container : [Track GA event in Piwik using Tally](https://forms.houseoftraining.lu/Track-GA-event-in-Piwik-using-Tally)

Yes, I would like to have a custom event with those values.

Thank you  
Jeff

---

<div class="post-metadata">

**Author:** ![kuba](https://dub1.discourse-cdn.com/flex005/user_avatar/community.piwik.pro/kuba/32/7_2.png) [@kuba](https://community.piwik.pro/u/kuba)\
**Post date:** [March 3, 2023, 1:07pm UTC](https://community.piwik.pro/t/track-ga-event-in-piwik-using-tally/1722/4 "2023-03-03T13:07:47Z")

</div>

The way tally handles form submit is a bit weird. Indeed, a datalayer event is pushed, but the structure makes it really hard to use in Tag Manager.

```auto
{
  "0": "event",
  "1": "Tally.FormSubmitted",
  "2": {
    "event_category": "/Track-GA-event-in-Piwik-using-Tally",
    "event_label": "Track GA event in Piwik using Tally",
    "non_interaction": true
  }
}

```

It would be much easier if it was something that’s standarized in some way, like:

```auto
{
  "event": "Tally.FormSubmitted",
  "event_category": "/Track-GA-event-in-Piwik-using-Tally",
  "event_label": "Track GA event in Piwik using Tally",
  "non_interaction": true
}

```

I don’t think there’s an easy way to solve it for now besides writing a really custom javascript code that would intercept such event. So, iterating through datalayer to find an object with first property set to `Tally.FormSubmitted`. I’m also not sure what would be the value besides catching the information that a form has been submitted. It’s a pitty that this event does not contain additional data such as the picked option (yes/no).

---

<div class="post-metadata">

**Author:** ![kuba](https://dub1.discourse-cdn.com/flex005/user_avatar/community.piwik.pro/kuba/32/7_2.png) [@kuba](https://community.piwik.pro/u/kuba)\
**Post date:** [March 3, 2023, 1:11pm UTC](https://community.piwik.pro/t/track-ga-event-in-piwik-using-tally/1722/5 "2023-03-03T13:11:05Z")

</div>

Other option would be to create a trigger that accepts all datalayer events with condition that checks the following dataLayer variables:

![image](https://europe1.discourse-cdn.com/flex005/uploads/piwikpro/original/2X/1/1d3629d111202d39deec45e78ef9268baac6e48f.png)

But as you can see, it does not look clean at all.

---

<div class="post-metadata">

**Author:** ![Jeff](https://avatars.discourse-cdn.com/v4/letter/j/e19b73/32.png) [@Jeff](https://community.piwik.pro/u/Jeff)\
**Post date:** [March 3, 2023, 1:13pm UTC](https://community.piwik.pro/t/track-ga-event-in-piwik-using-tally/1722/6 "2023-03-03T13:13:44Z")

</div>

Yes indeed, the data is not clean at all. I will open a ticket with them.

I wanted to track this event, because I will show a popup to visitors to participate in a survey. If they responded to the survey, I would no longer show them the popup. (If this is even possible)

I will just redirect to a different page and track that.

Thank you for your quick help.  
Jeff

---

<div class="post-metadata">

**Author:** ![kuba](https://dub1.discourse-cdn.com/flex005/user_avatar/community.piwik.pro/kuba/32/7_2.png) [@kuba](https://community.piwik.pro/u/kuba)\
**Post date:** [March 3, 2023, 1:23pm UTC](https://community.piwik.pro/t/track-ga-event-in-piwik-using-tally/1722/7 "2023-03-03T13:23:30Z")

</div>

You would have to set some value in local storage / cookie after the survey is completed. But yes, that should be possible. It’s weird that tally doesn’t even push a standard form submit event.

---

<div class="post-metadata">

**Author:** ![Jeff](https://avatars.discourse-cdn.com/v4/letter/j/e19b73/32.png) [@Jeff](https://community.piwik.pro/u/Jeff)\
**Post date:** [March 3, 2023, 2:44pm UTC](https://community.piwik.pro/t/track-ga-event-in-piwik-using-tally/1722/8 "2023-03-03T14:44:25Z")

</div>

This is the reponse from tally:

> Filip Minev [11 minutes ago](https://tallyforms.slack.com/archives/C01A5DUTXS6/p1677853950245069?thread_ts=1677849906.621799&cid=C01A5DUTXS6)
> 
> This is the format we sent the data
> 
> ```auto
> { "event" : "Tally.FormSubmitted", "event_category": "/votre-avis-compte", "event_label": "Votre avis compte", "non_interaction": true }
> 
> ```
> 
> Don’t know why you don’t see it like that in Piwik pro

---

<div class="post-metadata">

**Author:** ![kuba](https://dub1.discourse-cdn.com/flex005/user_avatar/community.piwik.pro/kuba/32/7_2.png) [@kuba](https://community.piwik.pro/u/kuba)\
**Post date:** [March 3, 2023, 4:39pm UTC](https://community.piwik.pro/t/track-ga-event-in-piwik-using-tally/1722/9 "2023-03-03T16:39:54Z")

</div>

Here’s the snapshot of datalayer read with `console.log` and it doesn’t look like that:

![image](https://europe1.discourse-cdn.com/flex005/uploads/piwikpro/original/2X/b/b4b11aabb7b1a398e12a6562072be5c598941d49.png)

---

<div class="post-metadata">

**Author:** ![Jeff](https://avatars.discourse-cdn.com/v4/letter/j/e19b73/32.png) [@Jeff](https://community.piwik.pro/u/Jeff)\
**Post date:** [March 6, 2023, 11:04am UTC](https://community.piwik.pro/t/track-ga-event-in-piwik-using-tally/1722/10 "2023-03-06T11:04:49Z")

</div>

And here is the response from Tally:

> This is the gtag event format we follow, which comes from [GA’s documentation](https://developers.google.com/tag-platform/devguides/events#universal_analytics_events).
> 
> `gtag('event', <action>, { 'event_category': <category>, 'event_label': <label>, 'value': <value> });`
> 
> So in the case of the Form submit, it will look like so:
> 
> `gtag("event", "Tally.FormSubmitted", { "event_category": "/Track-GA-event-in-Piwik-using-Tally", "event_label": "Track GA event in Piwik using Tally", "non_interaction": true });`
> 
> This is meant to work with GA, but I’m not familiar with Pikiw PRO and how they expect the data to be formatted.
> 
> ([イベント &nbsp;|&nbsp; タグ &nbsp;|&nbsp; Google for Developers](https://developers.google.com/tag-platform/devguides/events#universal_analytics_events))
> 
> Alternatively, you can listen to the Form submit event and trigger your own custom code if that would solve the issue for you.

---

<div class="post-metadata">

**Author:** ![kuba](https://dub1.discourse-cdn.com/flex005/user_avatar/community.piwik.pro/kuba/32/7_2.png) [@kuba](https://community.piwik.pro/u/kuba)\
**Post date:** [March 6, 2023, 11:32am UTC](https://community.piwik.pro/t/track-ga-event-in-piwik-using-tally/1722/11 "2023-03-06T11:32:40Z")

</div>

I don’t know how gtag relates to datalayer when it comes to structure, but clearly the final format cannot be easily read by Piwik PRO.

When it comes to the form submit, I don’t see such event. So, most likely Tally is handling the form in a custom way. I just copied the HTML of the form to my dev env and it generated an event. For some reason it does not work for your example form:

 ![image](https://europe1.discourse-cdn.com/flex005/uploads/piwikpro/original/2X/f/fe45eb76acff45dd53a7c832d8620fd14bc10eff.png)
