Removing Analytics plugin from WP

[ad_1]

I have a client who wants me to remove the existing Google Analytics for Woocommerce plugin and add the Google Tag via GTM and to continue with setup

What is the best way to do it, so the minimum of data is lost in this process?

I prepared the Google Tag in GTM, but all the events like view_item_list, begin_checkout etc will stop recording data if I dont add them through GTM, correct?

Is it the best way to deactivate the plugin and then right away publish the Google Tag in GTM?

Thank you all!

[ad_2]
2 Comments
  1. If you use GTM4WP plugin to inject GTM it has built in Enhanced E-commerce support for Woo so you won’t lose any data and continue to track Ecom events fine. The author has a GTM template you can use.

    Of course, test using GTM preview mode and GA Debug as well

  2. If you place your Google Analytics tag in GTM, it should still work the same. You can also technically still have your event tags hard-coded on the website, but it’s not ideal. Reason is, there’s always a chance your event fires before GTM loads the Google Analytics tag. Therefore, most people like to hold everything in GTM and set up protections there.

    If you give your events to whoever is setting up gtm, they should be able to add them there.

    Edit: to add clarity – this is only if you’re using custom events or if you hard-coded event triggers on specific pages. If you’re using a standard GA4 data stream with the default events, all you need to move is the GA4 tag to GTM and events will be unaffected.

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer