How to Add Google Analytics Tag in Google Tag Manager
1. Google Tag Manager Set up
- Go to the Google Tag Manager website ([https://tagmanager.google.com](https://tagmanager.google.com/)) and sign in with your Google account.
- Create a new Google Tag Manager account for your website/application if you haven't already.
- Follow the on-screen instructions to set up your Web-container. A container is a snippet of code that needs to be added to your website/application.
2. Adding the Google Tag Manager code to your website/application
- Once you've created the container, you'll be provided with a GTM container code snippet.
- Copy the entire code snippet provided.
- Paste the code snippet into the `<head>` section of your website's HTML code. This should be added before the closing `</head>` tag.
- Save the changes and publish your website/application.
3. Setting up a Google Analytics Tag in Google Tag Manager
- Go back to the Google Tag Manager interface.
- Access your container by clicking on its name.
- Click on "Tags" in the left sidebar menu.
- Click on the "New" button to create a new tag.
- Give your tag a descriptive name, such as "Google Analytics - Widget Click Event."
- Choose the tag type. For Google Analytics, select "Google Analytics: **: GA4 Configuration**."
- Configure the tag by specifying the Measurement ID of your Google Analytics property. You can find the Measurement ID in your Google Analytics account under Data Streams → Web stream details.
- Choose the appropriate track type based on your requirements, such as "Event" for tracking widget clicks.
- Set the tag firing option under Advanced settings to “once per page”.
- Save the tag.
4. Create a Trigger for the Tag
- Click on "Triggers" in the left sidebar menu.
- Click on the "New" button to create a new trigger.
- Give your trigger a descriptive name, such as "Widget Click Trigger."
- Select the trigger to fire on “Some Clicks”.
- Choose the “Click Element” trigger type, the condition as “matches CSS selector”, and the value as “.container__CompanyIcon-sc-qtelua-5.dmnmBT”.
- Save the trigger.
5. Preview and Debug
- In the Google Tag Manager interface, click on the "Preview" button in the top-right corner. This enables the preview mode.
- Open your website/application in a separate browser tab or window.
- With the preview mode enabled, any changes you make in Google Tag Manager will be visible in the preview pane.
- Navigate to the page where the widget is located and interact with the widget to trigger the event you want to track.
- In the preview pane, you'll see the tags and triggers firing, as well as the associated data being sent to Google Analytics.
- Use the debug information provided to ensure that the tag is firing correctly and capturing the desired data.
- If any issues are identified, go back to Google Tag Manager to make the necessary adjustments to the tag or trigger configuration.
- Repeat the preview and debug process until you're satisfied with the tracking implementation.
6. Publish Changes in Google Tag Manager
- Once you have created the tag and trigger, click on the "Submit" button in the top-right corner of the Google Tag Manager interface.
- Provide a version name and description for the changes you made.
- Click on the "Publish" button to publish the changes.
How to Publish Web Messenger by Using Google Tag Manager
About Google Tag Manager (GTM) Google Tag Manager is a free tool that allows you manage and deploy marketing tags on your website or mobile app without having to modify the code. For more information you can visit their website. If you do not have an ...
How to Connect Google Dialogflow?
To connect Google Dialogflow, you need to have a Google Dialogflow account. Please go to https://dialogflow.com/ to create an account. Once you create your account, please go to Console. After that, click Create Agent button in the left menu. If you ...
How to Use Commerce Manager
Prerequisites If your Facebook Business Page is a new page, please make sure it is verified (see How to Create a Facebook Business Manager (FBM)?). Set your page settings. Make sure that a minimum of 10/13 of page settings are completed. Go to “Meta ...
How to Create a Facebook Business Manager (FBM)
The first thing you need to do is go to the Facebook Business Manager (FBM). Go to https://business.facebook.com/ site and your business page. If you haven't opened an account yet, open an account for your business. Here, we recommend that an email ...
Commerce Manager Limitations
Limitations For Commerce Manager 1- Overall Limitations 1.1- Missing Integration notification There must be an integration added to publish an assistant with the Commerce module. 1.2- Missing catalog notification There must be a catalog added to ...