top of page
  • Writer's pictureCynthia Levin

Installing GA4 the Tag on Your Website

Chances are, you’ve read our previous blog, GA4: The Next Generation of Web Analytics, detailing how GA4 differs from Universal Analytics. And you’ve decided to make the leap? Good.

If you're interested in making the most of GA4 for your business, there are a few steps you can take:

  1. First, make sure you have a plan in place for how you want to use GA4, including what metrics you want to track and what insights you hope to gain.

  2. Familiarize yourself with the new features and functionality of GA4, and consider reaching out to a digital marketing expert if you need help getting started.

While there may be a learning curve as you adjust to the new platform, the benefits of GA4's enhanced tracking capabilities and machine learning insights make it a valuable tool for any business looking to improve their digital presence.

However, before any of that, we simply need to make sure your site is gathering data and sending them to the GA4 platform. The following sections describe how to do that.

Adding GA4 to your website can be done in a few different ways depending on your specific setup. The three common methods are: adding GA4 via on-page tag, using Google Tag Manager (GTM), and integrating it within platforms like Wix or Squarespace.

Before you can add your GA4 tag to your site, you have to create the property. To do that, navigate to your existing Google Analytics account. Navigate to the “Admin” section. Near the top you’ll see an option called “GA4 Setup Assistant.” Click that link. You’ll then see a section called “I want to create a new Google Analytics 4 property.” In that section, click the “Get Started” button.

(If all you see is a section called “Explore and set up your GA4 property” with a button called “Go to your GA4 property,” this means that Google already set up a property for you and it’s likely gathering data. If that’s the case, you’re in good shape and don’t need to add your GA4 tag, but you’ll still need to configure your account, which will be the topic of our next post.)

Once you click the “Get Started” button, follow the wizard so that it builds a new GA4 property for you. When you’re done creating the property, click into your Webstream and look for your “Measurement ID.” It typically starts with “G-“ and then has a 10-character string after it.

Read on to see how to add the GA4 code to your site, depending on your setup.


Adding GA4 via On-Page Tag:

One way to implement GA4 is by adding the tracking code directly to your website's pages. Here's how you can do it:

  1. Access your GA4 property: Log in to your Google Analytics account and navigate to the Admin section. Select your GA4 property from the dropdown menu.

  2. Obtain the tracking code: In the Property column, click on "Data Streams" and then "Web." Follow the instructions to set up a new web data stream, and you'll be provided with a tracking code snippet.

  3. Insert the tracking code: Copy the tracking code and paste it into the HTML source code of every page on your website, just before the closing </head> tag.

  4. Verify the implementation: Once the code is added, verify the implementation by visiting your website in one tab and using another tab to check the GA4 Real time report to see whether GA4 data is being collected in your Google Analytics account.


Using Google Tag Manager (GTM):

Google Tag Manager is a powerful tool that simplifies the process of adding and managing various tags, including GA4. This set of instructions assumes you have a GTM account and container already set up for your site. Follow these steps to set up GA4 using GTM:

  1. Find the GA4 webstream "Measurement ID" described earlier.

  2. In your GTM container, create a new tag. Choose the "Google Analytics: GA4 Configuration" tag type and enter your GA4 tracking ID in the “Measurement ID” field.

  3. Configure triggers to determine when the GA4 tag should fire. Common triggers include "All Pages" (most common) or specific page views. Once you've set up your tags and triggers, publish the changes in GTM, and the GA4 tracking will be active on your website.


Integrating GA4 within Wix or Squarespace:

If you're using website builders like Wix or Squarespace, adding GA4 involves a slightly different process:

  • Wix: In your Wix account, go to the "Marketing Integrations" section. Select "Google Analytics" and choose "Use Another Analytics Tool." Enter your GA4 Measurement ID and save the changes. Wix will automatically add the necessary tracking code to your website.

  • Squarespace: In your Squarespace account, navigate to the "Settings" tab and select "Advanced." Click on "External API Keys" and choose "Google Analytics." Enter your GA4 Measurement ID, save the changes, and Squarespace will handle the integration for you.

Remember to test and verify that GA4 is successfully tracking data after implementation, regardless of the method you choose. This ensures that you're collecting accurate analytics for your website.


If you're feeling overwhelmed by the idea of migrating your analytics to GA4, don't worry, you don't have to do it alone. The team at CMCollective is here to help. Our digital marketing experts have extensive experience with GA4 and can guide you through the migration process, ensuring a smooth transition and minimizing any disruptions to your data tracking.

We can also help you make the most of GA4's advanced features, such as machine learning insights and cross-device tracking, to gain a deeper understanding of your audience and improve your online performance.

So, if you're ready to take your analytics to the next level with GA4, contact CMCollective today. Our team is ready to help you get started.

16 views0 comments


bottom of page