Download
We're evolving to serve you better! This current forum has transitioned to read-only mode. For new discussions, support, and engagement, we've moved to GitHub Discussions.

Google Analytics in TechNews Theme

  • #2907
    Avatar photo[anonymous]

    Hi,

    Really love using Publii and I have tried to find the answer about Google Analytics in this forum.

    However, I couldn’t find the answer and I wasn’t sure if it’s theme dependant?

    I am using the theme TechNews and I have a Google Analytics code that I am placing in the custom HTML tool. I have tried different options, e.g. placing:

    • head
    • body
    • footer
    • AMP head
    • AMP Footer
    • before every post
    • after every poster

    Do you have any sugesstions where to put the GA code to make it work or do I need to put in a combination of several places?

    thanks a lot in advance!!

    #2910
    Avatar photoBob

    Just put the code into the head section.

    #3646
    Avatar photo[anonymous]
    [anonymous] wrote:

    Just put the code into the head section.

    I suppose the same goes for Stat Counter or any other similar service?

    #3649
    Avatar photoBob

    It depends on the scripts/services, but usually yes.