Can I duplicate a GA4 property? - google-analytics

I have a website, let's call it "X" and I tagged it using Google Tag Manager and I track it using Google Analytics 4. I duplicated the website (let's call it "Y") and I need to tag it again with GTM and track it with GA4. Do I have to tag and track everything again from scratch or can I duplicate GA4's property and GTM's container and make changes to it?

You have to create a new Property to configure in GA4 and retrieve the measurement id. For the GTM you can export the container and import it into a new one after which only change the measurement id with the new one.

Related

Add Google Ads custom variable to the existing Pixel via Google Tag Manager

I've created a Google Ads custom variable client_id and would like to add it to the existing Pixel that is set up on the website via GTM. However, I cannot find any documentation on how to do it via Google Tag Manager. There're instructions on how to
do it by adding a custom variable to an event snippet on the website, but there's no information regarding its setup via GTM.
Does anyone know how to add a Google Ads custom variable to the existing Pixel via GTM? Also, this variable needs to be dynamic as it should pick up different values.
Here's how the existing Google Ads tag looks:
Any suggestions would be helpful. Thank you in advance!

Implementing User-ID With Google Tag Manager

I have added Google Tag Manager to our site, and using the data layer inserted several custom dimensions, including 'user_id'
Data Layer with user_id shown
The Google Analytics variable in Tag Manager is configured to pass these data layer variables into the coresponding dimensions:
Tag Manager Variable & Dimensions in Analytics
I know this is working as I am able to add this as a secondary dimension in Analytics when viewing reports:
Analytics with Dimension Shown
However, the user view that is created when I have set up the User-Id isnt showing anything:
Creating the User View
We installed Tag Manager using the recommended steps:
Installation of Tag Manager
Do we also need to add the 'Global Site Tag Tracking Code'?
How to Implement the User-ID in your tracking code
If not, what am I doing wrong?
You're actually REALLY close. You actually don't need to create the custom dimension.
The correct way is to set the userId field in your GA tag (I did it through a GA variable so it is applied everywhere).
Yes, that is exactly correct (what #XTOTHEL answered above), but for those who are reading this, I found these two blog posts helpful (esp if you are using GTM):
GA UA: https://www.analyticsmania.com/post/google-analytics-user-id-with-google-tag-manager/
GA4: https://www.analyticsmania.com/post/google-analytics-4-user-id/
And of course, the GA docs: https://support.google.com/tagmanager/answer/4565987?hl=en

Track custom events on GA inserted by GTM

I have inserted Google Analytics using Google Tag Manager on my site.
Often, an site has only one analytics. But when you have multiple, analytics recommends to name them.
Custom Events using ga("send", "...") only apply to the global analytics instance. I need to track an Ajax Form with custom events. If you have a named instance, you need to call ga("INSTANCE_NAME.send", "...").
The problem: Tag Manager is inserting the analytics with an name (gtm1) even having only one instance. This way, i need always to set the name on custom events and on my case, i can't do it because i use an plugin.
What i need is to remove the name inserted by tag manager and use an global instance, but i want to keep using the tag manager to insert the tag.
In the advanced settings there is a field where you can override the tracker name (if you use a settings variable you need to check "enable override settings" first). I haven't done this for some time, but it used to be that if you enabled the field but did not enter a name the tracker name would revert to the default.

google analytics & google tag manager : Where to read the data

I had to integrate the GTM and track few data into a webpage and im facing some comprehsion issues. I dont think it's code wise, but i don't get where i'm supposed to see the data that im tracking.
i've successfully added the GTM code into my application and defined some data to be sent inside the dataLayer variable, after that i can go to the GTM admin panel and choose to Preview and Debug, so i can see the data i'm trying to track and everything seems allright. Therefore, i don't know what happens to them next. I don't know where i can see the data that i track, where they are stored. I've linked my GTM account to my GA account so i can see the traffic and other datas, but not the ones i've put inside my dataLayer object.
Anyone know what are the next steps ?
Here's some screenshots of my tag
Thanks
I think Simo Ohava - the GTM "god" - is explaining it quite well:
Datalayer Basics:
https://www.simoahava.com/analytics/data-layer/
Google Tag Manager & Datalayer:
https://www.simoahava.com/analytics/google-tag-manager-data-model/
As far as I understand you, all your questions (including basics and how to access via tag manager - and more) are pretty nice answered/explained there.
I've linked my GTM account to my GA account
What do you mean by this? Where did you "link" the data? GTM tracks data via the tags you define to fire for various interactions on the pages, including pageviews, events, and transactions (all known as "hits"). Each tag that fires in GTM has an associated Universal Analytics property ID that comes from your Google Analytics account. You must include this ID in all your tags. This is where you tell GTM tags to send your data and this is where in GA you will find the reports on your data.
Simply pushing data to the dataLayer does nothing unless
you're also pushing events to it and using those events to trigger tags to fire
You've defined GTM variables to grab the data being pushed in
Your tags are configure to pull that data into your reports
EDIT
To pull data into GTM from the dataLayer, you need to do the following:
Make sure your data is pushed in the following format:
datalayer.push({
'event': 'your event',
'page': 'custom/path/path',
'otherData': 'custom dimension1',
'otherData2': 'custom metric1'
})
Create a Data Layer variable, whose name can be anything, and whose value is the name of the dataLayer key.
Include the Data Layer variable's name in whatever tag you need the data to apply to. For example, if it's a custom dimension you need to associate to your pageview, then go into the Advanced Configuration of the tag and add the data into the Custom Dimension section (remember to configure your CD in GA, and to include the index). You can be associating any kind of data to the specific tag (eg. page path, page title, page name).
Test and then publish your tag!

Add Custom Variable in every Analytics Tag of a container

Using GTM, is it possibile to add a custom variable in every Google Analytics Classic Tag at once?
I have a container with 50 GA tags and now i have to pass a custom variable to each of them, and it seems possibile only doing it updating every single tag.
I've tried to pass a custom variable in a tag fired on all pages at page view, setting it at session level but debugging with WASP i find that only on pageview the custom variable is passed to the _utm.gif and not on other events.
Anyone has any clue for this?
Thanks

Resources