views:

21

answers:

1

I am not entirely finished with my website, and I am using apaches authentication to demand password and username when entering the site.

I wonder, will this cause any problems with using and testing Google analytics?

Should I first "open" and remove the authorization before using GA?

Thanks

+2  A: 

GA (and any other tracking tool out there) records data when the actual page is viewed (or if you specifically push information to it with an API or something).

So it doesn't matter that you have apache authentication on the site. All that really means is that data will only be recorded for people who know the user/pass and can get passed the prompt, vs. random people who come to the site and don't.

But FYI a common practice is to have a separate GA (or other tracking tool) account for testing/dev environments, so that when you go live and start collecting data from users visiting your site (who don't have to jump through the user/pw hoop), that previous data won't "muddy the waters".

In other words, setup a second account in GA and have your GA code point to that account while you are testing/deving your site and then when you are ready to go live / push into production, change the account number to the real GA account.

Unless you don't care about the GA data in the test environment. If that is the case, simply comment out the GA code so it doesn't send data while you are testing/deving your site.

Crayon Violent