How to Exclude Traffic in Google Analytics using Cookies

Have you ever wanted to know how to remove any of your clicks, visits and page views from showing up in Google Analytics?  Well I’ve got a way that should save you some time and make your web analytics tracking capabilities that much more precise and best of all its easy to implement.

In order to take advantage of this you’ll need to have the Google Analytics Tracking Code installed and have access to your website hosting to upload a file.  With that, let’s get to the important stuff and show you how you can do this.

Step 1: Create a web page with the following code in the body section of the HTML page and upload it to the root directory on your website.  Don’t know HTML?  No problem, here is a pre-coded web page with this code already added for you!  Download it now!

<body onLoad=”javascript:pageTracker._setVar(‘expert_cookie’);”>

Note: In order for this to work correctly please ensure that the Google Analytics tracking code is installed on every page of your website.

Step 2: Create an exclude filter in Google Analytics by taking the following steps…

- Login to your Google Analytics account

- Navigate to the “Filter Manager” at the bottom of the Account overview page in Google Analytics.

- Click the “+Add Filter” link on the right hand side of the Filter Manager page

- Enter the following information to create your exclude filter…

Note: If you are using the download cookie.html page on your website the “Filter Pattern” will need to equal the contents of the setVar string

- Select the website or websites that you want to apply the exclude filter to and click “Save Changes

Step 3: Visit the Cookie HTML page to setup the cookie with your web browser and now when you go to a page on your website that you are tracking with Google Analytics it won’t track you anymore.

As you can see it’s pretty easy to get this setup and you’ll wonder just how you ever lived without doing this before.  Enjoy your more precise Google Analytics tracking!


Leave a Reply

Your email address will not be published. Required fields are marked *

This blog is kept spam free by WP-SpamFree.