SEO
Explore SEO services →
On-page SEO
Keyword research & mappingContent optimisationTitle & meta optimisationInternal linking strategyLocal SEO & Google Business Profile
Link building
Digital PR & authority linksNiche edits & guest postsLocal citationsCompetitor link gap analysisToxic link cleanup & disavow
Technical fixes
Core Web Vitals & site speedCrawl & indexation fixesSchema & structured dataSite migrations without traffic lossMobile usability fixes
One-time SEO fixes
Broken links & 404 cleanupRedirect chain cleanupDuplicate content & canonicalsSitemap & robots.txt repairSearch Console error fixesImage optimisationTraffic-drop & penalty recovery
AEO / GEO
Explore AI search →
Answer engines (AEO)
AEO strategy & answer-ready contentFAQ & featured snippet optimisationVoice search optimisationPeople Also Ask targeting
Generative engines (GEO)
ChatGPT visibilityGoogle AI OverviewsPerplexity & Gemini visibilityLLM brand mention tracking
AI SEO foundations
Entity & knowledge graph optimisationAI-ready schema markupDigital PR for AI citationsAI crawler access & llms.txt
Free AI search audits
Free AEO auditFree GEO audit
Web Design
Explore web design →
Website types
Business websitesHigh-converting landing pagesE-commerce websitesBooking & appointment websitesSaaS & startup websites
Platforms
WordPress developmentShopify developmentWebflow developmentCustom & headless builds
Improve your site
Website redesignUI/UX designSpeed optimisationConversion rate optimisationCare & maintenance plans
By industry
Clinic & healthcare websitesReal estate websitesRestaurant & hospitality websitesProfessional services websitesHome services websites
Automation
Explore automation →
Leads & sales
Lead qualification serviceInstant lead follow-upCRM setup (HubSpot, GoHighLevel)Online booking and remindersMissed call follow-up
Marketing
Automated email and SMS follow-upWhatsApp business setupGoogle review collectionAutomated social media posting
AI assistants
AI chatbot for your websiteAI phone answeringAI customer supportAdmin and back-office automation
By industry
For clinics and practicesFor real estate agentsFor home service businessesFor online stores
Marketing
Explore paid marketing →
Paid media (PPC)
Google Ads managementMeta (Facebook & Instagram) adsYouTube adsLinkedIn adsRemarketing campaigns
Social & content
Social media managementContent marketingShort-form video contentBranding & identity
Retention & data
Email marketingSMS marketingAnalytics & conversion trackingMarketing reporting dashboards
Our Work
Case studies →
Industries
E-commerceSaaS & technologyProfessional servicesHospitality & travelHealthcare & wellnessReal estate & propertyConsumer brandsVentures & startups
Resources
Read the blog →
Learn
Blog
Blog topics
Local SEOGoogle Business ProfileTechnical SEOSEO FundamentalsLink BuildingSEO Tools and DataAI Search and AI ToolsSocial Media Marketing
Free audits
Free SEO auditFree AEO auditFree GEO auditFree ads auditFree UI/UX reviewFree automation audit
Who is BRO
About us →
Company
About usContactBlog
How we work
The relevance paradoxGrowth ecosystem4-stage methodology
Our work
PortfolioCase studiesIndustries
Free SEO audit ↗
Technical SEO

How to Block Spammy Referrers From Your Website and Analytics

Ways to stop referral spam polluting your analytics and server: filters, server rules, firewalls and plugins, and when each one makes sense.

B.R.O. Editorial TeamPublished 25 September 2025
3 min read3 sections

Ways to stop referral spam polluting your analytics and server: filters, server rules, firewalls and plugins, and when each one makes sense.

In this article 3 sections · 3 min read
  1. Two types of referral spam
  2. Ways to block it
  3. Avoid overdoing it

Referral spam shows up as fake visits from strange domains in your analytics. Some of it never touches your website at all; some is real bot traffic hitting your server. Either way, it distorts your data and can waste server resources.

01Two types of referral spam

  • Ghost spam: fake hits sent directly to your analytics property without visiting your site. Server rules cannot stop these; analytics filtering can.
  • Crawler spam: bots that actually visit your site, often repeatedly. These can be blocked at the server or firewall.

Google Analytics 4 is less affected by ghost spam than older versions, but crawler spam still appears.

02Ways to block it

1. Filter it in Analytics

Use data filters and segments to exclude suspicious domains from reports. This cleans your data without affecting your site.

2. Block at the server

On Apache servers you can deny requests based on the referring domain in the .htaccess file. On Nginx, the equivalent is a rule in the server configuration. See editing .htaccess safely.

3. Use a firewall or CDN

Services such as Cloudflare let you block countries, user agents or referrers and filter known bad bots, which is often the most effective option for heavy traffic.

4. Use a security plugin

On WordPress, security and firewall plugins can block bad bots and spam referrers with less technical effort.

5. Report spam

Where spam sites abuse search or advertising services, you can report them to the relevant platform.

03Avoid overdoing it

  • Do not block legitimate referrers or search engine crawlers.
  • Keep block lists maintained; spam domains change often.
  • Watch for side effects after adding server rules.

Clean data is the foundation for good decisions. Our analytics and conversion tracking service can set up filtering and reporting you can trust. Related: internal site search spam.

Technical SEOWant this handled for you?

Our team can review your situation and tell you exactly what to fix first.

Free SEO audit ↗
Found this useful?
Written by the B.R.O. team

B.R.O. (Be Relevant Online) helps businesses get found and grow online through SEO, AI search, paid media, websites and automation. Every guide is written from hands-on client work and reviewed for accuracy.

About usMore on Technical SEOAsk us a question

FAQ

Questions, answered.

Still unsure? Talk to us directly and get a straight answer, not a sales pitch.

Fake or bot traffic that appears in analytics with suspicious referring domains.

No. Ghost spam never visits your site; it must be filtered in analytics.

Mostly it distorts your data, though heavy bot traffic can also strain your server.

Let’s talk growth

Want help with technical seo?

Tell us about your business and we will suggest the most useful next steps.

01Share your goals below
02We review your current setup
03You get a clear growth plan

Or email us directly: contact@berelevantonline.com

Prefer a deep-dive first? Free SEO audit →

FREE · NO OBLIGATION
Start the conversation

Share a few details and a strategist will get back to you with next steps.

    No spam, no obligation. Your details stay with B.R.O.

    Free consultationNo lock-in pitchReal strategist reply

    Prefer email? contact@berelevantonline.com

    BE RELEVANT ONLINENeed help with Technical SEO?
    Free SEO audit ↗