Written by Brian Cray on March 14th, 2009
Inbound links answer a basic question: How do people find my site? But that's just half the equation. People come and go. Where are they all going? Are people leaving your website because they aren't engaged or because they are following one of your outbound links?
Those outcomes suggest two different things about the effectiveness of your website. In the first case your website isn't effective; in the second case your visitors read enough to at least follow your links.
Outbound links are not tracked by Google Analytics despite their potential value. That is to say without a little programming wizardry and Google Analytics hackery [insert geek smirk here].
The above code works by telling Google Analytics to record a page view for every outbound link. As a result, Google sees outbound links as another page view on your website under the subdirectory /outgoing/. So, for example, if someone clicks a link to http://briancray.com/ on your website, Google Analytics will record a page view of /outgoing/http://briancray.com/. See the example screenshot below taken from the Content Overview section of Google Analytics:
Step 2: Google Analytics hackery to filter outbound links
You may have already realized that the above script introduced a slight problem: Your page views now account for actual page views as well as outbound links. If this doesn't concern you, you can quit reading now and enjoy the script. If this does concern you, here's step–by– screenshots to explain how to filter outbound links in Google Analytics:
Once you apply your new custom segment in Google Analytics, you will only see traffic details for the outbound links. To filter out the outbound links and see only normal traffic, you would set the "Condition" dropdown to "Does not contain" instead of "Starts with."