Veeresh Devireddy
Veeresh Devireddy

Reputation: 1145

Google Analytics - Multipe Visits and Events

Can anyone please help me clarify below queries?

  1. Including GA code two times in a same page cause double visitor counts?

  2. Using below/event code directly on the page, does it creates an events directly in the GA portal? Or first do we have to create 'Video' as event first in the GA portal and then call this so that it will map itself? Ex: _gaq.push(['_trackEvent', 'Videos', 'Play', 'Gone With the Wind']);

  3. In google chrome extensions, while publishing it will asks for the GA id, and we provide, and if we keep main GA code in the extension pages(popup.html) too, then does it count as twice?

Upvotes: 0

Views: 98

Answers (1)

CrayonViolent
CrayonViolent

Reputation: 32532

1. Including GA code two times in a same page cause double visitor counts?

If it's the same code pointing to the same account# and you aren't doing anything inbetween like deleting cookies, then no, it will not cause double visitor count. However, it will cause double page view count.

Using below/event code directly on the page, does it creates an events directly in the GA portal? Or first do we have to create 'Video' as event first in the GA portal and then call this so that it will map itself? Ex: _gaq.push(['_trackEvent', 'Videos', 'Play', 'Gone With the Wind']);

Traditional GA does not require you to do anything special in the interface for this. You should see "Video" show up as a value in the Category dimension automatically.

In google chrome extensions, while publishing it will asks for the GA id, and we provide, and if we keep main GA code in the extension pages(popup.html) too, then does it count as twice?

I think you may be confusing your Google Developer Account ID with the Account# associated with your google analytics account, but if your extension outputs GA code and there is also GA code on the page and it points to the same account, then yes, it will count some things twice (see your first question).

To be clear, every time a _trackPageview is invoked, a page view will be tracked. So if you have multiple calls to that then it will count multiple times. If the visitor cookie isn't reset or broken, it will count as the same visit(or).

Upvotes: 2

Related Questions