How do I mark a specific event in Google Universal Analytics as 'NonInteraction' ?

siddharth_singh
Silver Contributor
Silver Contributor siddharth_singh

Hi,

I looked into the mapping details for GUA tag and could not find an option to set mark a specific Event tracking as 'NonInteracting'. By default all events being sent to Google are considered as Interacting right now.

We have certain events that need to be triggered on page-load but should not be considered as interacting.

I looked in the GUA template as well, and there is no code to send the 'nonInteraction:true' status to Google.

Please let me know if there is no other means but to update the template for this feature.

Regards

Siddharth

6 REPLIES 6

How do I mark a specific event in Google Universal Analytics as 'NonInteraction' ?

davidcreason
Employee Emeritus
davidcreason

@siddharth_singh if you're using the most recent version of GUA (analytics.js) from our marketplace, the template does include the nonInteraction setting. However, it is not populated in the list of mappings and has to be added manually.

 From the tag's Mapping Settings

  1. Click Add Custom
  2. Enter nonInteraction and click OK
  3. Close, and Save & Publish

gua_non_interation.png

Giving the variable event_non_interaction any value will cause GUA to set it to true. We would recommend setting it to "1" for true as per our best practices for Booleans. 

 

If you're using the most recent version of GUA (gtag.js) from our marketplace, the mapping is slightly different. 

 From the tag's Mapping Settings

  1. Click Add Custom
  2. Enter event.non_interaction and click OK
  3. Close, and Save & Publish

gua_non_interation_gtag.png

How do I mark a specific event in Google Universal Analytics as 'NonInteraction' ?

siddharth_singh
Silver Contributor
Silver Contributor siddharth_singh

It looks like we are using GUA template which might be around 3-4 years old.

The only code in the Template for nonInteraction I found was:

if (u.data.nonInteraction) {u.all("set", "nonInteraction", true)};

Going with the above solution, ALL tracking was getting marked as non-Interaction including PageViews.

I believe we have to move to a new template. Please confirm.

Note: In our QA env. we were using a newer version of GUA tag created for testing purposes and the solution provided was working there.

How do I mark a specific event in Google Universal Analytics as 'NonInteraction' ?

davidcreason
Employee Emeritus
davidcreason

@siddharth_singh First, I would recommend updating to the most recent template. Second, as a point of clarification, you should only set the Non Interaction variable on events that require it, for other events that do not need it, do not set anything. You could also set the value to false with JS code, and it should keep the condition from triggering, but not setting it is the better option. 

How do I mark a specific event in Google Universal Analytics as 'NonInteraction' ?

ak87qa
Bronze Contributor
Bronze Contributor ak87qa

Hi @davidcreason,
I'm using Extensions to add event tags for a website that is using Google Analytics (analytics.js). One of the tags I have created is an event tag that fires on hover (mouseover). I want to make this tag a non interaction. Is it possible this post is outdated?

How do I mark a specific event in Google Universal Analytics as 'NonInteraction' ?

StevenSlings
Rookie Contributor
StevenSlings

I have the same question, would like to know how to send a GA event with the value of non-interactive = true. 

Highlighted

How do I mark a specific event in Google Universal Analytics as 'NonInteraction' ?

Community Manager
Community Manager

The latest tag template for the Google Analytics (analytics.js) tag supports nonInteraction events. Run the Tag Status Checker to see if your tag needs to be updated. The template simply looks for "truthiness" for this mapping, so set a variable to 1 or true in an extension, then map to nonInteraction in the mapping toolbox. It's in the Standard mapping group.

ga-analytics-non-interaction-mapping.png

Remember to "Accept as Solution" when your question has been answered and to give kudos to helpful replies.