It’s an age-old design question if your core web content should be above the fold or if users are happy to scroll down to see it. tools such as ClickTale (below) provide a really powerful solution to show you exactly how far down your page your visitors are scrolling. However, with 70% of businesses using Google Analytics, it would be really great to have that kind of insight built into Google Analytics reports.
Unfortunately, this is something that they have never provided.
Scroll reach tracking plugin
In order to try and get around this, I’ve built a Google Analytics plugin that uses JQuery and event tracking to measure how far down your pages your visitors are scrolling.
How it works
The script works by working out the height of your webpage and dividing it into ten even splits (10% scroll). It then finds the height of the user’s browser window and works out how many of those 10% splits the visitor can see and fires an event to Google Analytics for each of those 10% splits (10%, 20%, 30% etc.)
Then, if the user starts to scroll down the page, it fires an event when they reach the next 10% split and then another event for every 10% split thereafter.
It’s built to only fire each 10% split event once, so if a user scrolls all the way down the page and back up you would get 10 events rather than 20 or more.
The events fired use the following code:
_gaq.push([‘_trackEvent’, title, ‘scroll reach’, ‘10%’,10,true]);
Where title is the page title that the user is currently on and the 10% changes to reflect the split of the page that the user has scrolled to. The last field is set to true and this tells Google Analytics not to consider these events in bounce rate calculations so that your pages don’t suddenly have zero percent bounce rate after setting this tracking up.
The value of the event is set to the value of the scroll position, so 10% would give 10 etc. so that the average scroll depth is given in Google Analytics and you can see whether your “average user” is seeing your important content nice and easily.
- Requires JQuery to be installed
- Should be placed below the call for JQuery and the main Google Analytics tracking code
- Uses the Asynchronous tracking script (gaq, not gat)
- I recommend placing in an external JS file so you can easily include it across your site without having to copy and paste lots of code into every page.
You can download the plugin here:
If you have any questions or want to suggest any improvements, leave a comment below.