Site logo

[Support request] migrating from google analytics to google tag manager

Home Forums Support [Support request] migrating from google analytics to google tag manager

Home Forums Support migrating from google analytics to google tag manager

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #2040380
    Devesh

    Hi GP Team,

    I am trying to migrate from Google analytics to Google tag manager and wanted help on what’s the best way to go about it in Generatepress
    I currently have the Google Analytics tag implemented using GP Hook Element-wp- head.

    For GTM implementation, I was referring to this GP article
    Do I need to replace the existing analytics tag in Hook element with the GTM tag referred to as first block of code in the article (to be added under wp-head). Pls see extract of code posted in private area (even this GA code mentions gtag.js but this was set up only using GA account)

    Or do i need to add the GTM code separately by creating another wp head element, while retaining the existing Google Analytics tag element as it is. I have heard this can lead to duplication and existing GA code ) needs to be replaced with GTM header code, but not sure and want to keep the GA history intact.
    Would appreciate your help here.

    #2040691
    Elvin
    Staff
    Customer Support

    Hi Devesh,

    The script for these 2 can be placed on 1 Hook element. 🙂

    Just make sure you add HTML comment tag like <!-- Google Tag Manager --> before their respective <script> tag so you know which script is which incase you want to remove them in the future.

    As for completely removing GA, it’s really up to you but it’s good to have GA removed and just connect your GA to the GTM. This way, you’re only maintaining 1 code.

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.