Get variant name in report and or GTM

  • 28 September 2018
  • 1 reply
  • 32 views

Hi, maybe it is a basic one but I didn’t find any info on how to achieve this.

I want to be able to:

  1. Track each variant individualy via GTM in order to visualize stats per variant, I found this info but for UA, not for GTM
  2. Get variant name in a report: csv download or zapier integration: right now we get the variant letter, but would be a lot clearer if we could get the complete name we gave to the variant.

Any idea how to do it?


1 reply

Found this for GTM in case someone else is looking for it.

You can set the “value” of the page name or the title this way:

  1. At GTM create a personalized javascript variable with this script: ub.page.variantId

  2. Now at your GA configuration in GTM > More Settings > Fields to set > you can add a Field name and Value. In order to get your variant into the Page reports in GA you should select “page” and in the value field you put the variable you created at step 1: {{your variable}}

Here you can see all the values you can change or set from there

Reply