Looking at the documentation on the web, it seems to be a common practise to track outbound links as a virtual pageview with a URL like /outgoing/{original_url}. But a lot of that documentation is from before Google added events to analytics. Which is the preferred method nowadays – page views or events?
Looking at the documentation on the web, it seems to be a common practise
Share
The ‘correct’ way is to track outbound links, downloads, etc. as events. – Creating virtual pageviews is a hack, from back when events wasn’t released.
Virtual pageview tracking artificially inflates the number of aggregated pageview, and thereby polutes the data, so best-practice is to avoid this if possible.
However, there are cases where virtual-pageview-tracking is the only solution, and thats when you need to track the outbound link (or download etc.) as a goal – and thereby being able to optimize against this goal in AdWords.
Examples include AdWords optimization with regard to PDF-download.
If this is not the case, use event-tracking.
—
A standard snippet is (which simply is included in the specific
<a>‘sonclick-attribute):Google has another solution to this:
http://www.google.com/support/googleanalytics/bin/answer.py?hl=en&answer=55527
Which tracks the events, waits 100ms and the redirects to the external link – this imo, is not the best solution.
—
Another thing to remember, is that the onclick-event is not fired when the user right-clicks -> open in tab, or the equilivant middle-click.