In a Hurry?
Home
/
/
Add Google Analytics 4 to a site using Google Tag Manager

Add Google Analytics 4 to a site using Google Tag Manager

Share Article:

You need a Google Analytics 4 account created. If you haven’t made one, then follow this guide. Also, you should have installed Google Tag Manager on your site. If you haven’t added Google Tag Manager to your site, you can check out our Google Tag Manager Installation Guide for WordPress or Shopify.

Get the measurement ID from Google Analytics 4

Login to your Google Analytics account.

Click “Admin”.

Make sure you’ve selected the correct property (account) and select “Data Streams” under “Data collection and modification”.

Select the website that you want to implement in Google Analytics 4.

Click on the measurement ID to copy it on your clipboard.

You can paste it into a text editor or notepad. You will need this later on.

Set up Google Tag Manager

Note: If you haven’t added Google Tag Manager to your site, you can check out our Google Tag Manager Installation Guides.

Go to http://tagmanager.google.com and sign in with your account details.

Select the container that is set up on your website.

Go to “Tags”:

Click “New” and rename your tag. It is recommended that it contains a mention to Google Analytics 4 as it would make it easier in the future to locate the tags you are looking for.

Note: When creating new tags it’s recommended to define a naming convention from the beginning, this keeps your Google Tag Manager set up neatly organized and easy to maintain for many years to come. [Abbreviated Name Of Tool]_[Use for this tag] is a good start. e.g: “GA_TrackingCode”

Click on the “Tag Configuration” icon and select “Google Tag”:

Note: In early September 2023, the new Google tag has now replaced the Google Analytics 4: GA4 Configuration tag with two settings variables. Read more here.

Paste the Measurement ID that you copied from Google Analytics 4 earlier.

Note: if you would like to set up the configuration settings and event settings, please find the valid parameters here:

Next, scroll down and click on the Trigger icon below to set up a trigger for this tag.

Select “Initialization- All Pages”. This is to fire the Google Analytics 4 on all pages on your website (recommended).

You are now ready to save your settings by clicking “Save”:

Next, go to the “Overview” on the sidebar. This is how your Google Tag Manager overview dashboard should look like:

If everything looks okay, you are ready to hit “Submit”.

In the Submission Configuration panel, you will be given the chance to add a name and description to this version. After you have done so, hit “Publish”.

Note: Adding a name and description is optional but recommended. You should enter the information here that will make it easy to know what changes are being made.

You will now be taken to see the summary of the changes you’ve just made:

Verify your set-up with a Tag Assistant Companion

Select the container that you have already set up.

Select “Preview”.

A new tab will appear to connect a Tag Assistant to your site. Key in your website URL and click “Connect”.

This will open a new window to verify your website with a debug parameter at the end of your website URL. We recommend closing this window and using an extension instead, as explained below.

Next, download the “Tag Assistant Companion” extension from this link here.

Refresh the Google Tag Manager page, click “Preview”, and then “Connect” again.

This time, a new tab will appear instead of a new window with the installed Tag Assistant Companion. The Tag Assistant Companion icon should appear in the tab as shown below, which means it is now connected:

Next, navigate through the pages of your website. The Tag Assistant Companion will automatically load your page events as seen on the left:

Refer to this link here for the definition of each page view trigger.

A shaped icon on the left represents each page on your website. For more tag details messages such as blue, red, yellow, or green icons, please refer to this link here.

To troubleshoot any issues encountered in the Tag Assistant Companion, refer to this link here.

Verify your setup inside Google Analytics

Login to your Google Analytics 4 dashboard by heading over to https://analytics.google.com

Click “Admin” from the bottom corner and select “DebugView”.

If your GA4 setup is done correctly,  you should be able to see some test engagement events you did prior.

Alternatively, you may verify through the real-time report under the “Report” icon on the sidebar.

In another Google Chrome tab or window, open your website URL.

Now, go back to the Google Analytics 4 tab and wait a few seconds.

You should see (at least) 1 active user on the website:

Tags:
Share Article:
    Mon-Fri: 9am - 5pm
    United Kingdom
    Scaling Trade © 2025

    Book a Free no BS Discovery Call

    Pick a time to meet and chat with one of the team

    Start your Live AI Demo in 3 easy steps

    Step 01

    Start a chat with our AI bot on either FaceBook or Instagram (Links Below)

    Step 02

    Send the message DEMO to get started

    Step 03

    Our AI Bot will ask you a couple of questions to get the demo setup for you and then hand you over to your own personalised demo bot to try out!

    Drop us a message

    If you have questions or an enquiry this form is for you...

    Book Your Live Demo

    Book your no-pressure, no BS Demo.

    When Should We Call You?

    Pick a time for one of our team to contact you.

    Get The Latest News & Offers

    Every Month we publish the Trade Pulse Magazine packed with sales and marketing tips, tricks and special offers.