Forums

[resolved] How to add Google Analytics to Hosted wordpress site? (8 posts)

  1. demogirl
    Member
    Posted 2 years ago #

    Can anyone tell me how I add the code to my site? I do not know where to go/ Thanks

  2. esmi
    Theme Diva & Forum Moderator
    Posted 2 years ago #

    Try adding it to footer.php before the </body></html> tags using Admin/Appearance/Editor

  3. chshahid2k
    Member
    Posted 1 year ago #

    only in footer.php or i have to add it in all wordpress files?

  4. Rev. Voodoo
    Volunteer Moderator
    Posted 1 year ago #

    just footer.php

    the footer file is always loaded, with all your posts, pages, etc

  5. diannetrussell
    Member
    Posted 1 year ago #

    Hello Esmi, appreciate your help. I had the same problem and have now gone to find my footer.php and discovered that I have a whole bunch of them:
    wp-admin/admin-footer.php
    wp-includes/theme-compat/footer.php
    AND
    two for every theme I'm currently considering:
    a mytheme/footer.php
    and
    a mytheme/sidebar-footer.php

    My question is: does the GA tracking code have to go into all these files? Or just one master file?

  6. esmi
    Theme Diva & Forum Moderator
    Posted 1 year ago #

    In your theme's footer.php file - mytheme/footer.php.

  7. diannetrussell
    Member
    Posted 1 year ago #

    Thanks! Now I can get moving!

  8. evw1960
    Member
    Posted 1 year ago #

    Hi All!

    Doesn't the Google Analytics for WordPress plugin do all of this for you?

Topic Closed

This topic has been closed to new replies.

About this Topic