Monday 20 April 2009

How to block your own PC from skewing your site’s Google Analytics statistics

So, your web site is live and you're making small tweaks here and there and connecting to your site to test the changes - but you don't want your own PC to skew your site’s Google Analytics statistics… ie: you want to see how many "real" hits your site is attracting.
Here are 2 tricks that should assist you:

Method 1 relies on installing and configuring firewall software on your PC;
Method 2 involves editing the Windows hosts file.

Method 1: A crude way of blocking access to the Google Analytics site – so that you don't clock up hits would be to configure a firewall on your PC to prevent connections to the whole
www.google-analytics.com domain.

I have tried it with the free
Comodo Internet Security (which is a free bundle of a firewall and virus protection) and configured the firewall part to have a “blocked network zone” -> and added the “host name”: www.google-analytics.com
{and google-analytics.com}


This will then block ALL traffic from your PC to the www.google-analytics.com site. {That’s why I said that it’s “crude”}

The page will load, but appear to wait for a connection to complete – that’s the browser trying to connect to www.google-analytics.com

Download from here:
http://personalfirewall.comodo.com/download_firewall.html

Note: it’s a bit of a pain to start with because it’s got to learn which apps are safe - so it pops up and asks you if an app or connection is safe. To start with, I put it in “learning mode”.


Method 2: You could add google-analytics.com and www.google-analytics.com both as 127.0.0.1 to the windows host file as follows:
Edit the 'hosts' file: edit %SystemRoot%\system32\drivers\etc\hosts
and add the following 2 lines:
127.0.0.1 google-analytics.com
127.0.0.1 www.google-analytics.com

Save the file and voila - all traffic destined for google-analytics will get routed to your local PC!

I prefer method 2 (although installing a firewall and learning how to use it is not a waste of time!)

Let me know which method works best for you?

Update:
Here's Method 3 which I found on the Google Analytics help page - so I guess it's the preferred option ;) but method 2 above is simpler.
From here: https://www.google.com/support/googleanalytics/bin/answer.py?answer=55481&ctx=sibling

In summary,
if you have a fixed IP address (or range) then use Google Analytic's "filter" that will "filter all traffic from an IP address".
if you have a dynamic IP address (ie: using an ADSL line) then create a filter that will exclude traffic by Cookie content.

0 comments:

Post a Comment

Share this article

Recent Posts by HandyTechTipper

HTT topics cloud

Money saving tips (93) tips (72) time saving tip (63) free (56) free programs (48) free software (48) free apps (46) Calculator (27) free services (27) Discovery Vitality (20) Skype (18) discount (18) Vodacom (16) Discovery credit card (15) Cape Town (14) SkypeOut (14) VOIP (14) cellphone (14) Discovery Health (13) International calls (12) SMS (11) Vodacom PrePaid (11) save electricity (11) saving electricity (11) Vodago (10) mobile Internet (10) reduce power usage (10) stop crime (10) ADSL (9) PrePaid ADSL (9) cash back (9) tagga (9) Electricity Usage Calculator (8) Firearm licence (8) neighborhood watch (8) Firearm license renewal (7) GPS (7) SIP (7) airtime (7) compare prices (7) credit card (7) firearm renewal (7) send free SMS (7) stolen goods (7) Firefox (6) Mugabe (6) Telkom (6) pre-paid electricity (6) solar heating (6) time switch (6) CellC (5) DIY (5) Eskom load shedding (5) MS office (5) Nokia N70 (5) Zimbabwe (5) anti-theft (5) best cell phone apps (5) flag as stolen (5) geyser (5) phishing (5) thermostat setting (5) 3G settings (4) Inflation (4) KeyFinder (4) Yebo4Less (4) free internet (4) gmail (4) life lesson (4) load shedding (4) second hand goods bill (4) time switch on your geyser (4) FIFa world cup soccer (3) Firefox3 (3) GPRS settings (3) Gun license renewal (3) Joomla (3) MS Outlook (3) MTN (3) Nokia (3) Nokia Navigator (3) Online backup (3) Robert Mugabe (3) TopTV (3) Twitter (3) ZenCart (3) cell phone contract (3) email to SMS (3) free email (3) free entry (3) free games (3) liquidation (3) save environment (3) scam (3) setup cell phone in South Africa (3) tourism (3) 567CapeTalk (2) Act (2) Bluetooth (2) Celine Dion (2) Concert (2) Edge settings (2) Linux (2) Lotto results (2) Opera to Firefox (2) WWE wrestling (2) backup (2) bank account (2) browser war (2) eTV wrestling (2) elderly (2) emoticons (2) event organising (2) excel (2) false advertising (2) funny (2) lotto (2) lotto plus results (2) mobile setup in South Africa (2) national lottery (2) personal email security (2) pre-emptive load shedding (2) privacy (2) save paper (2) second hand goods (2) software development (2) toll free (2) used goods (2) webcams (2) wooden bowl (2) 0800 (1) Asperger's (1) Eskom load shedding monitor (1) Google Earth (1) VAS rates (1) World Cup soccer 2010 (1) backup software (1) hoax (1) load shedding schedule (1) sql client (1)

www.priceisright.co.za

Live Traffic Feed

 

Be notified of
page updates
it's private
powered by
ChangeDetection

Copyright © 2008 HandyTechTipper. All articles are released under the Creative Commons Attribution 2.5 South Africa license, unless where otherwise stated.