Google Tag Manager Interference with Google Analytics

I had following problem:

  1. Google Tag Manager was wrapped in a div and therefore was not recording properly
  2. Google Analytics was been recorded twice and that was messing with Bounce rates etc…

What I did:

  1. Remove Google Tag Manager
  2. Remove the Classic Analytics code from the “Analytics” tab in the Page Settings

Suddenly everything appeared to be all good.

Then…

I re-added the Google Tag Manager code into an embed widget and added it as the first element of each page and now following issues appear to be happening:

  1. Google Analytics is tracking twice (no idea why?)
  2. GTM is not recording wrapped in div

Any plan on how I can fix this?

Do you happen to have preview links and what-not again, or a specific page you’re testing on? I checked the links from your last post and it appears as though GTM isn’t installed on most pages and Analytics, at least on the home page, only shows up once.

It looks like GTM may add the analytics code in itself, so that could be the source of it tracking twice.

GTM not working in the div may be trickier. Aside from placing it in the <head> tag without the <noscript> or placing it before the </body> tag, adding it in via javascript may be the only other way.