How to Migrate from Google Analytics to Google Tag Manager

How to Migrate from Google Analytics to Google Tag Manager

What is it?

Have you ever noticed that your Google Analytics account is showing incorrect sessions, conversions, etc. or not working properly because of incorrect implementation of Google Analytics or your developer is not familiar with setting up Google Analytics? Google Tag Manager is a perfect tool for you to implement all the codes without any hassle provided that you are comfortable with JavaScript, web applications, and web servers. Migrating Google Analytics to Google tag Manager can be as daunting as a new tag implementation on the entire site. On large sites, implementing a tag manager like GTM may impose serious challenges, if not implemented correctly. However, migrating to a tag manager is well worth the ride.

Why is Google Tag Manager Important?

Using a tag manager will pay you back many times over - you will save time, effort, and money with every single tag deployment. Mistakes will be easier and quicker to correct. Remember, a tag is a snippet of code that tracks user behavior and sends information about activities on a website to third parties.
Today in this article, we are going to tell you how to implement Google Analytics code via GTM or how to migrate from Google Analytics to Google Tag Manager safely.

Why should you use GTM?

  • A tag manager, like GTM, is agile. It offers a centralized tag management. Complete control of tags - what, when and how to fire.
  • Page speed improved, page loads faster as multiple tracking codes, snippets, pixels are removed
  • Repeated coordination with the developers for minor changes get reduced, hence avoiding unnecessary delays in tracking data
  • Staging environment is available to make sure your tags are firing without any flaws, hence no loss in data collection
  • Versions are being maintained for tracking implementation by date & time, so you can revert anytime to the previous version if you are not satisfied with your new implementation. No need to change the codes again & again in tags/triggers.
  • It makes tags deployment easy. Both, Google all products (analytics, conversion tracking, remarketing) and third-party tags can be deployed.
  • It is reliable as chances of errors or missing tags are reduced with one-time installation. It makes the overall process fast as no need to add the code every time and allows you to make swift decisions
  • More time to analyze data, as not required to reupload any codes on the pages
  • Debugger and preview mode features help diagnose the errors
  • High level of security

How to migrate GA tags to GTM on a very large website?

1. GTM Migration setup

  • Create a GTM account and your first container: Sign up on GTM and fill your website details. A few sections need to be filled while setting up a GTM account.

  • Once you fill out the information, GTM will provide you with two tags and both the tags need to be placed on each page of the website. Script tag will be placed in the head section and no script tag in the body section.
  • Once you are done with the GTM account setup, list the codes which you want to migrate.

2. Migrating the tags to GTM

  • Deploy the tags in the newly created GTM account according to your requirements. Let’s take an example of a Google Analytics tag.
  • Create one new Google Analytics property ID test view for the intermediate period. Let's call it GA code GA(UA-123456).

3. Intermediate deployment of GA tags through GTM and comparison

  • Deploy GA test ID (UA-123456) through GTM
  • Implement all the checklist tags (UA, Events, Conversions, etc.) on GA(UA-123456) within the GTM, preview, & debug to ensure that all the tags are firing well.
  • Review and publish the container.
  • Volume comparison: Compare the overall volume numbers between the existing GA property and the GA test property (UA-123456).
  • Settings comparison: Check all old events and that there are equivalent, identically named events inside GA (UA-123456).

4. Final deployment for GA tags through GTM and clean-up

Once both volume and settings have been compared, the following needs to happen:

  • Remove all existing GA codes instances from the website. This includes GA tracking snippet, event codes, ecommerce tags etc.
  • Ensure that you have removed all Google Analytics codes from the website for which you have created tags and triggers in the GTM account.
  • Once you remove all the codes from the website. Replace GA test property ID GA(UA-123456) with existing GA property.
  • Publish the container with GA existing property ID.
  • Be certain, that the data collection is being going on real time for the tracked
    • Users
    • Pageviews
    • Sessions
    • Top Pages
    • Top Events
    • Bounce Rate
    • Conversion Rate


Probable cause


Double tracking
Not removing old analytics code implementation correctly
Ensure all GA hard code tags have been removed
Bounce Rate dropped
User id feature implemented through GTM, not existed in GA
Ensure all GA hard code tags have been removed
Page load time increases
Some custom scripts are taking a long time to load
Check all 3rd party publisher tags load time & remove the one which is taking highest time
Some tags not firing
Tag firing priority needs to be set-up
Tag firing priority needs to be set-up
Event names convention
Tags are setup differently than hard code tags
Ensure 1:1 replication of events
Referral traffic spike
Your own domain is not cross-linked
Ensure you have setup cross-linking between domains properly as they were before.

If you still have doubts about the process or are looking for GTM migration for your website, contact me.

You might also like

Start your project