AdWords is now Google Ads. Our new name reflects the full range of advertising options we offer across Search, Display, YouTube, and more. Learn more

Analytics
5.2K members online now
5.2K members online now
Dive into multiple domain (Cross/Sub) tracking, implementing Ecommerce and Enhanced Ecommerce, setting up Event tracking, and Universal Analytics code.
 
Guide Me
star_border
Reply

How do I fix "Bad Event Tracking Code"

Visitor ✭ ✭ ✭
# 1
Visitor ✭ ✭ ✭

(not set) entry present in reports for property XYZ

 

And when I click on Details this is what shows up:

 

The Landing Pages report has a (not set) entry.

A pageview hit must precede event hits in order for the event hits to include the page that they fire from. When event hits aren't preceded by a pageview, Google Analytics doesn't have the page for the event hits, so their page is (not set).

Verify that tracking code for property XYZ sends a pageview hit before sending any events.

 

How do I fix this? As it is affecting my Alexa Rank as well. 

TIA.

Regards,

DM.

1 Expert replyverified_user

How do I fix "Bad Event Tracking Code"

Top Contributor
# 2
Top Contributor

Hi,

 

It seems that you are sending an event before a pageview was sent. Make sure that you have your GA tracking code in the head section of your pages and that you have a ga('send', 'pageview') command before your ga('send', 'event'...) command. Hope this helps.

 


Arnold Majlath, Google Analytics Top Contributor
Was my response helpful? If yes, please accept it as solution.
Circle Me On Google+ | Visit me @ Redfly Digital

How do I fix "Bad Event Tracking Code"

Visitor ✭ ✭ ✭
# 3
Visitor ✭ ✭ ✭

That was not helpful at all, can you give more detailed guidelines on how to fix this issue?

How do I fix "Bad Event Tracking Code"

Visitor ✭ ✭ ✭
# 4
Visitor ✭ ✭ ✭

https://www.lunametrics.com/blog/2015/01/08/fix-google-analytics-notifications/

 

How to fix it:
If you’re firing an event before you fire a pageview, adjust your code so that your event hits always come after the pageview hit. e.g.:

ga('send', 'event', 'eventCategory', 'eventAction');
ga('send', 'pageview');

becomes

ga('send', 'pageview');
ga('send', 'event', 'eventCategory', 'eventAction');