Google Analytics: What is Referral Spam and How to get rid of it

We were recently working with a client on their google analytics. The client found some referrals that seemed suspicious because they had spam titles. After some research we found that there is name for this spam it is called Referral Spam.

Definition from Wikipedia:

Referrer spam (also known as log spam or referrer bombing) is a kind of spamdexing (spamming aimed at search engines). The technique involves making repeated web site requests using a fake referer URL to the site the spammer wishes to advertise.[2] Sites that publish their access logs, including referer statistics, will then inadvertently link back to the spammer’s site. These links will be indexed by search engines as they crawl the access logs.

This benefits the spammer because the free link improves the spammer site’s search engine ranking owing to link-counting algorithms that search engines use.

So after a little searching on google I found this post : Definitive Guide to Removing Referral Spam. There is also a historical blacklist of referral spam, which is very helpful as a reference. In this post the author explains how to get rid of the spam by creating filters that all the traffic being reported is only coming from my hostname, use segment to eliminate spam referrals, and to exclude bots from the search results. Then Test, Test, Test!

We are still in the testing phase but so far it seems to work and it takes a little effort to set up but it is well worth having accurate Google Analytics results.