Google Analytics Code - Help

by 4 replies
5
I partner up with an X company and the X company has some sort of pre-design websites and I chose one for my own URL. I'd like to add GA to the site, so I went to Google to generate one and Google said the code needs to be added in the header, but the X company said their pre-design website only works with GA code generate for the footer. They said other partners gave them GA code for the footer. I don't see an option in GA to generate code for footer. Anyone knows how to do this? :confused: Any help is appreciated. Thank you.
#programming #analytics #code #google
  • It doesn't matter. It's a script tag, and shoudn't really matter if it's set in the footer on in the header.

    So don't worry, the snippet google generates for you works in the footer also.
  • feel free to put it in the footer. doesn't matter.

    PS: just saying the same thing as the previous post to convince you.

    PSS: different between putting in header and footer.

    if you put in header, the script runs before the site content is loaded. if it's in footer, the site content loads before the script runs. the reason i think the recommend putting in header is to capture analytics data as soon as the user visits your site, that way, even if the user visits your site and leaves right after, just before the content is loaded, they'll be tracked...the opposite is for putting in footer.

    if you put in footer, visits that come and leave before the site is loaded (which is not so likely) don't count.

    all the best
    • [1] reply

    • Thank you all for replying to this thread. I'll apply that. Greatly appreciated.
      • [1] reply

Next Topics on Trending Feed

  • 5

    I partner up with an X company and the X company has some sort of pre-design websites and I chose one for my own URL. I'd like to add GA to the site, so I went to Google to generate one and Google said the code needs to be added in the header, but the X company said their pre-design website only works with GA code generate for the footer. They said other partners gave them GA code for the footer. I don't see an option in GA to generate code for footer. Anyone knows how to do this? :confused: Any help is appreciated. Thank you.