How do I block my own visits in Google Analytics?

11 replies
I apologize if this has already been covered a bunch of times. Nothing I've tried so far has worked.

I am trying to block my own visits in Google analytics so I can accurately test conversions on my squeeze page.

I've tried setting a cookie in my browser, and then filtering out that cookie inside of analytics.

Tried setting the cookie in two different ways:

Here: (edit....won't let me post links since I'm a new member)

But my own visits still seem to be showing up.

Has anyone had any success blocking their own visits in Google?

Any advice at all?

Thanks very much!
Elliott
#analytics #block #google #visits
  • Profile picture of the author AllanJames
    Just set up a filter to exclude your IP address. Check the Help for details - it's a wee touch complicated to explain here.
    Signature
    50% Sales Conversions?? YES!, check my blog.
    {{ DiscussionBoard.errors[1327518].message }}
    • Originally Posted by AllanJames View Post

      Just set up a filter to exclude your IP address. Check the Help for details - it's a wee touch complicated to explain here.
      Ah if only it were that easy... Unfortunately, I'm on a dynamic IP. I also work on a laptop, and regularly work at coffee shops or a number of other places other than my home office... Tks anyway
      {{ DiscussionBoard.errors[1329698].message }}
      • Profile picture of the author Voon
        How about disable javascript of your browser when you load your page?
        (I guess google analytics won't load since it is a javascript based?)

        Haven't tried that myself. Perhaps you could try one of these:

        1. Disable all javascript option in your browser when you surf your site.

        or

        2. Set your website URL as Restricted Site and disable javascript in Restricted Site Zone? (in IE only?)

        or

        3. Uses Firefox addon, that let you trigger javascript on/off when ever you like. (I'm using Web Developer addon)

        Hope that helps.
        Signature

        .

        {{ DiscussionBoard.errors[1330321].message }}
        • Originally Posted by Voon View Post

          How about disable javascript of your browser when you load your page?
          (I guess google analytics won't load since it is a javascript based?)

          Haven't tried that myself. Perhaps you could try one of these:

          1. Disable all javascript option in your browser when you surf your site.

          or

          2. Set your website URL as Restricted Site and disable javascript in Restricted Site Zone? (in IE only?)

          or

          3. Uses Firefox addon, that let you trigger javascript on/off when ever you like. (I'm using Web Developer addon)

          Hope that helps.

          I've installed a Firefox addon that lets me block the Google code. We'll find out shortly is that works..
          {{ DiscussionBoard.errors[1330830].message }}
  • Profile picture of the author Voon
    Alternatively after some googling.. (for windows)

    1. Open up c:\windows\system32\drivers\etc\hosts using notepad

    2. Append at the bottom and save the following:
    127.0.0.1 google's analytics domain (sorry can't post url)
    127.0.0.1 google's analytics ssl domain
    Signature

    .

    {{ DiscussionBoard.errors[1330447].message }}
    • Originally Posted by Voon View Post

      Alternatively after some googling.. (for windows)

      1. Open up c:windowssystem32driversetchosts using notepad

      2. Append at the bottom and save the following:
      127.0.0.1 google's analytics domain (sorry can't post url)
      127.0.0.1 google's analytics ssl domain
      Unfortunately (at least in this scenario), I'm a Mac guy...
      {{ DiscussionBoard.errors[1330824].message }}
  • Only pain in the butt is I have to wait a full day to find out if each thing I'm trying to fix works.. since it takes a day to show up in Google analytics... unless anyone knows any other ways.

    Thanks for all the help so far. I just joined WF.. Seems like a great resource
    {{ DiscussionBoard.errors[1330837].message }}
  • Profile picture of the author Voon
    Ops.. but good news! Mac has a hosts file too..
    Refer to <wikipedia>/wiki/Hosts_file (aww.. can't post url again =/)

    Look forward to hear some good news from you..

    p/s: welcome to WF.. and myself too..
    Signature

    .

    {{ DiscussionBoard.errors[1331818].message }}
  • Good news... I think I got it. As I said, it takes a full day to find out if what I changed took effect, but it looks like what I changed yesterday worked.

    It looks like Google added a new page (I'm sure it wasn't there before), about how to block your own traffic when you're on a dynamic ip.

    I'll add this here in case anyone else ever needs help with this....

    You just load a unique cookie into your own browser.

    To do so, you can add some javascript in the body tag of a page on your site that your visitors WON'T have access to (this is important because anyone who visits this page, won't get counted in your traffic reports).

    Code:
    body onLoad="javascript:pageTracker._setVar('unique_name_of_your_cookie')"
    Then in Google Analytics, just set up a filter to exclude any users that have this cookie set (you can find help on this inside of Google analytics). It's that easy.

    Anyone else that you don't want to include visits from in your analytics, just have them visit this page too, like VA's, employees, etc...

    And that's it. This seems to be the easiest way to do it.

    Hope this helps someone!

    Elliott
    {{ DiscussionBoard.errors[1333806].message }}
  • Profile picture of the author Voon
    Good info, thanks for sharing...
    Signature

    .

    {{ DiscussionBoard.errors[1334032].message }}

Trending Topics