The Pros and Cons of Virtual Page View Tracking in Google Analytics

MoreVisibility - February 24, 2011

Last week, we dug into the pros and cons of event tracking with Google Analytics, which sets us up nicely to discuss the pros and cons of virtual page view tracking. With the combination of this week’s and last week’s blog posts, you should have enough information to make a decision on whether to go with event tracking or virtual page view tracking for an outbound link, a PDF file, an application, a video, or something else that you wish to track on your web site.

The philosophy behind setting something up as a virtual page view is to track something as a page view that currently cannot be tracked as such. The best example I can use to elaborate would be wanting to track something that your web site offers as a file download – Microsoft Word documents, Adobe PDF files, podcasts, and the like. You could use event tracking to track these file download interactions as events, but you could also use a virtual page view to track their downloads as page views, just like any other web page on your site.

For PDF and Microsoft Word types of files, you can use a JavaScript onClick event. However, another common situation in which you’d want to use a virtual page view is one where you have to edit the Google Analytics tracking code snippet itself. This happens a lot on web forms, where the page that the form lives on (example: /contact-us.php) is the same “page” that the subsequent confirmation page lives on. I put “page” in quotation marks because developers know it’s not the same page, but because Google Analytics can’t tell the difference between pages if the URL in the browser’s address bar is the same, you won’t see any views of that confirmation page in your reports. Therefore, you will have to use a virtual page view (e.g. use the _trackPageview function) on the confirmation page to tell Google Analytics that it’s recording data for a different page than the form page.

What else do you need to know about virtual page views? Check out the following list of pros and cons and compare it to last week’s blog post on event tracking, and you be the judge.

Virtual Page View Pros:

– Any item that is tracked using a virtual page view can be set up as a goal in Google Analytics. That’s because Google Analytics treats virtual page views and actual page views the same way (it considers them both as pages on your site). Therefore, you can set up your PDF file downloads as a goal, for example.

– You can differentiate pages that use the same URL in the browser’s address bar in your reports. This is great for any situation where the URL in the browser’s address bar does not change, like in the example above on web forms. This sometimes is also the case on a shopping cart checkout process – multiple pages using the same URL, making a great excuse for you to implement some virtual page views.

– All of the nice web analytics metrics that you have come to know and love are also collected and reported on when a visitor interacts with something set up with a virtual page view. Bounce rate, average time on page, and even the $Index metric are all available.

Virtual Page View Cons:

– Any virtual page view, if used by a visitor, will inflate your page view count in reports, along with other metrics. If, for example, you set up a virtual page view on an outbound link that leaves your web site, that action can increase your time on site and page view metrics artificially, which may be a burden to you.

– If you have lots of files and lots of actions to track as virtual page views, this could mean a sizable work-load for someone in your IT or web site development department. Unlike installing the standard Google Analytics tracking code, installing virtual page views is a manual process, and possibly, a costly one.

– All of the virtual page view data is mixed in with all of the actual / regular page view data in your content reports. You will have to make frequent use of the report’s filter tools, or possibly create an advanced segment or separate filtered profile to be able to view your virtual page view data.

Hope you enjoyed this two-part series! Let us know if you have any questions or comments – or your own pros and cons of using virtual page view tracking!

© 2024 MoreVisibility. All rights reserved.