Analytics & TestingMartech Zone Apps

Referrer SPAM List: How to Remove Referral Spam from Google Analytics Reporting

Have you ever checked your Google Analytics reports only to find some very strange referrers popping up in the reports? You go to their site and there’s no mention of you but there are a ton of other offers there. Guess what? Those people never actually referred traffic to your site.


If you didn’t realize how Google Analytics worked, basically a pixel is added to every page load that grabs a ton of data and sends it to Google’s Analytics engine. Google Analytics then deciphers the data and organizes it neatly into the reports that you’re looking at. No magic there!

But some idiotic spamming companies have deconstructed the Google Analytics pixel path and now fake the path and hit your Google Analytics instance. They get the UA code from the script that you have embedded in the page and then, from their server, they simply hit GA servers over and over until they begin popping up on your referral reports.

It’s truly evil because they never even initiated the visit from your site! In other words, there’s no means for your site to actually block them. I went around and around on this with our host who patiently explained what they were doing over and over and over until it got through my thick skull. It’s called a ghost referral or ghost referrer since they never actually touch your site at any time.

In all honesty, I’m still not sure why Google hasn’t simply started maintaining a database of referral spammers. What a great feature that would be for their platform. Since no visit actually occurs, these spammers are wreaking havoc with your reports. For one of our clients, referrer spam makes up over 13% of all of their site visits!

Create a Segment in Google Analytics that Blocks Referrer Spammers

  1. Sign in to your Google Analytics account.
  2. Open the View that includes the reports you want to use.
  3. Click the Reporting tab, then open the report you want.
  4. At the top of your report, click + Add Segment
  5. Name the segment All Traffic (No Spam)
  6. In your conditions, be sure to state exclude with source matches regex.
Exclude Referrer Spam Segment
  1. There’s an updated list of referrer spammers on Github that Piwik users are using and it’s pretty good. I’m pulling that list automatically below and formatting it properly with an OR statement after each domain (you can copy and paste it from the text area below into Google Analytics):
  1. Save the segment and it’s available to every property within your account.

You’ll see tons of server scripts and plugins out there to try and block referral spammers from your site. Don’t bother using them… remember that these weren’t actual visits to your site. The scripts these folks are using faked the GA pixel directly from their server and never even came to yours!

Douglas Karr

Douglas Karr is the founder of the Martech Zone and a recognized expert on digital transformation. Douglas has helped start several successful MarTech startups, has assisted in the due diligence of over $5 bil in Martech acquisitions and investments, and continues to launch his own platforms and services. He's a co-founder of Highbridge, a digital transformation consulting firm. Douglas is also a published author of a Dummie's guide and a business leadership book.

Related Articles


  1. It’s obnoxious upstream / downstream spam issues: The spammers spam it and then offer a remedy – that’s my guess.

    Have you checked IP blocks or anything to see if there’s a range to find them?

    Other ideas I’m trying to see if others have tried:

    1) I’d say reset the cookie to have a longer session time count as a visit but the bots will keep pinging the site. These things need to be treated as DDoS attacks because of the way they drain physical resources

    2) Make a new profile and put the new code in Google Tag Manager so the code isn’t as easy to skim. Also, making a new account and making like 4 profiles so the last number doesn’t end in -1 is another consideration. But, I’m guessing at this point the spammers are just auto-generating the UA numbers or ignoring UA numbers all together & using the campaign url builder tool

    1. Spam is becoming a huge issue nowadays. However, this post isn’t about your site or people actually spamming your site. They’re faking out Google Analytics. It shouldn’t impact your Adsense at all, but will mess up your Google Analytics.

  2. Thanks for your article Douglas. Great read. I absolutely hate spam, it has caused so many problems for my websites in the past, sometimes caused my wordpress sites to crash when i had a older version of wordpress.

    Definitely going to share this article on my site.

    Im currently starting a wordpress blog for marketers.

    1. Hi Sheena,

      It’s honestly really frustrating. The only benefit is that less-sophisticated analytics users will seek out the referrer and may buy their products or services. It’s a terribly cheap and ridiculous means of trying to trick less knowledgeable site owners.


What do you think?

This site uses Akismet to reduce spam. Learn how your comment data is processed.


Adblock Detected

Martech Zone is able to provide you this content at no cost because we monetize our site through ad revenue, affiliate links, and sponsorships. We would appreciate if you would remove your ad blocker as you view our site.