Using Events to Improve Bounce Rate in Google Analytics

By  on  

The bounce rate cited by Google Analytics for this blog has always been high and it's been discouraging.  Having a high bounce rate is bad, right?  Or does that mean someone found what they needed and left, which would be a win?  I'm not sure, but I was recently told that some people use event tracking to find a truer bounce rate.  If a user scrolls or clicks on something, that shouldn't be a bounce, right?  They're certainly interacting with the page!  With my redesign, I implemented this:

function removeEvents() {
	document.body.removeEventListener('click', sendInteractionEvent);
	window.removeEventListener('scroll', sendInteractionEvent);
}

function sendInteractionEvent() {
	ga('send', 'event', 'Page Interaction');
	removeEvents();
}

document.body.addEventListener('click', sendInteractionEvent);
window.addEventListener('scroll', sendInteractionEvent);

After adding this code, my bounce rate went down dramatically.  Tracking an event isn't gaming the system so I find this situation a bit odd.  Why does tracking an event, not firing a pageview, affect the bounce rate so much?  I'm not sure, maybe you can tell me!

Preventing Events from Affecting Bounce Rate

Let's say you don't want events to affect your bounce rate; you can use the following to do so:

ga('set', 'nonInteraction', true);

It's odd to me that an event would effect bounce rate, if the definition of a bounce rate is a user going to your site and immediately leaving. A pageview is not an event so....weird!

Recent Features

  • By
    5 Awesome New Mozilla Technologies You’ve Never Heard Of

    My trip to Mozilla Summit 2013 was incredible.  I've spent so much time focusing on my project that I had lost sight of all of the great work Mozillians were putting out.  MozSummit provided the perfect reminder of how brilliant my colleagues are and how much...

  • By
    An Interview with Eric Meyer

    Your early CSS books were instrumental in pushing my love for front end technologies. What was it about CSS that you fell in love with and drove you to write about it? At first blush, it was the simplicity of it as compared to the table-and-spacer...

Incredible Demos

  • By
    Create Twitter-Style Dropdowns Using MooTools

    Twitter does some great stuff with JavaScript. What I really appreciate about what they do is that there aren't any epic JS functionalities -- they're all simple touches. One of those simple touches is the "Login" dropdown on their homepage. I've taken...

  • By
    Using Dotter for Form Submissions

    One of the plugins I'm most proud of is Dotter. Dotter allows you to create the typical "Loading..." text without using animated images. I'm often asked what a sample usage of Dotter would be; form submission create the perfect situation. The following...

Discussion

  1. This is nice. I recently found this jQuery plugin (yeah, one likes mootools more ^^) http://scrolldepth.parsnip.io/ wich is firing every 25% of pagescroll.

    This way it’s more comfortable to tell if the quality is good. More Events = better content.

  2. Bounce rate depends on presence/absence of interaction. Navigating from one page of your blog to another counts as an interaction; scrolling, navigating to another website, playing a video on your website, etc does not count as interaction. You track such actions via events; and while doing so, you can choose if the event should be counted as an interaction or not.

  3. Joey

    Yes, but how/where is the code implemented? Do I just paste it anywhere in the site? Thanks.

  4. Leo

    Salman’s got it right.

    Google calculates a users time spent on a site by measuring the time between the first “hit” and last “hit”. The first “hit” happens when you load a page.

  5. Hi,
    The bounce rate is a nightmare for the webmasters, if it is on the higher side. In fact, the Google analytics is a best and free tool to stay informed about your website bounce rate.

    This article has the quality to assist many webmasters to understand the pros and cons of the bounce rate.

    Thanks for sharing a quality.
    kumar

  6. I disagree, I want my events to effect my bounce rate. I have a single page marketing site. So I register events on the menu items that are clicked to scroll to the next section. These are not bounces.

Wrap your code in <pre class="{language}"></pre> tags, link to a GitHub gist, JSFiddle fiddle, or CodePen pen to embed!