Google Analytics Implementation Guide
Our quick and easy implementation guide for Google Analytics 4 (GA4) will have you tracking your website traffic in not time!
First, let’s take a look at the TL; DR version:
- Account Creation
- Get your Google Account ready, create a GA property and start filling in information about your data stream
- Data Collection
- Finish creating your data stream, implement the tracking code and confirm data is being collected
- Events & Conversions
- Create and/or identify conversion events and custom events
- Ecommerce Tracking
- Enable ecommerce tracking and ensure the appropriate parameters are being passed
- Collection & Retention Settings
- Turn on Google signals, granular location & device data collection and ensure data retention is set to the max
- Data Filters & Exclusions
- Setup any necessary data filters and/or exclusions i.e., internal traffic
- Content Grouping
- Establish content groupings for large websites as needed
- Product Linking
- Connect Google Analytics to your other Google products like Google Ads & Search Console
- Custom Reports
- Configure any custom reports as needed
- Audits & Ongoing Maintenance
- Determine how audits and ongoing maintenance will be performed
Step 1: Account Creation
First, make sure you have a Google Account handy that you intend to use for managing your analytics properties. We recommend using separate accounts for personal and professional projects.
Next, go to analytics.google.com and click Start measuring (assuming this is your first account). If you already have analytics account, click Admin and in the Account column click Create property and begin filling out the property details.
Enter the website name (e.g., www.example.com) as the Property name, select your time zone and local currency. You can always come back and edit these details at a later time too.
Next Google asks for information about your business i.e., the industry category and business size. The following step asks you to choose your business objectives from the following options:
- Generate leads
- Drive online sales
- Raise brand awareness
- Examine user behavior
- Get baseline reports (this option can’t be combined with others)
These business objectives will be used by Google Analytics to automatically create reports once data collection begins.
Step 2: Data Collection
The last step to creating a new property in GA4 is to setup data collection. This is where you will select a platform (i.e., web for this guide) to create a new data stream for your new property.
When you select web the Set-up data stream menu below will appear. Input your website URL and stream name (we recommend using something like www.example.com web). We recommend enabling enhanced measurement at this stage as well (click the gear symbol to customize what is measured).
The next step is to implement the tracking code on your website. There’s three primary ways to implement the tracking code:
- Manually adding the gtag.js snippet to the <head> of each web page
- Implementing through Google Tag Manager (GTM)
- Native CMS integration or plugin
Option 1, manually adding the gtag.js snippet to all the web pages on your site isn’t recommend unless absolutely necessary. In most cases, implementing through Google Tag Manager (GTM) or finding a native CMS integration is the way to go.
Option 2, implementing Google Analytics 4 through GTM is fairly straightforward and provides a number of benefits (why we love GTM as SEOs). Basically, this requires setting up a container through tagmanager.google.com and implementing the gtm.js snippet (in place of gtag.js) in the <head> of each page. Here’s Google’s guide on setting up GTM to get started.
Option 3, integrations/plug-ins, will probably will work best for the majority of readers as it doesn’t require any coding. Finding a native CMS integration or plugin makes setting up GA4 incredibly easy. Thankfully Google put together a helpful list of all the platforms the accept a Google tag ID i.e., offer some form of native CMS integration.
The final part of this step is to check the realtime report once the tracking code is implemented to ensure data is being collected.
Step 3: Events & Conversions
Once data collection has been confirmed it’s important to setup conversion tracking and any important custom events.
Tracking conversions is arguably the important aspect of web analytics regardless of whether they’re sales or newsletters signs ups. Marking events as conversions will allow you to report on the actions that matter most to your business. Setting up conversions is also important because you can then:
- Bid on conversions through Google Ads
- Attribute credit to the correct marketing channels
- Remarket to users that haven’t converted
Google Analytics 4 makes tracking form submissions easy with enhanced measurement. Let’s jump to the next section for an overview on tracking sales for ecommerce websites.
Step 4: Ecommerce Tracking
Setting up tracking for ecommerce events collects shopping behavior data about your website users. This can help inform promotions, merchandising, product placement and other important business decisions.
How you measure ecommerce events for your website will depend largely on the CMS and/or ecommerce platform you use. For example, setting up Google Analytics for WooCommerce may only take a few minutes. On the other hand, setting up parameters for a full catalog of products using a custom ecommerce solution could take dozens of hours of coding. Google’s guides for measuring ecommerce and how to setup ecommerce events are great starting points if you’re ecommerce platform doesn’t have native support for GA4.
Step 5: Collection & Retention Settings
We recommend enabling both Google signals data collection and Granular location and device data collection in the Data Collection settings under Data Settings (screenshot below).
While setting up a new GA4 property it’s also important to make sure the data retention setting is set to the maximum (14 months for non-360 accounts). This should be the default for new accounts; however, it was set to 2 months in the past (and that’s not very useless in our opinion).
Step 6: Data Filters & Exclusions
It’s important to establish data filters and exclusions for internal traffic to avoid yourself and your team skewing metrics.
The best way to exclude traffic can vary depending on your team size, location and the use of static vs dynamic IPs. Excluding a static IP is easy to do with GA4, however most devices use dynamic IP addresses. For this reason, we recommend using cookies to exclude internal traffic.
Search Engine Journal has a great article on excluding internal traffic that we recommend checking out.
Step 7: Content Grouping
It can be helpful to group pages into custom buckets known as content groups, especially for larger websites. This allows you to view metrics for related groups of information in reports.
Content groupings require some technical skills and understanding. Custom variables can be configured and added to the Google tag on your web pages manually. Alternatively, we recommend using Google Tag Manager to create content groups when possible.
Step 8: Product Linking
We recommend linking all the Google products you and your business uses to your Google Analytics 4 account.
Connecting Google Ads and Google Search Console (GSC) allows additional reports to populate in GA4 (i.e., your natural search clicks and impressions, conversions from paid search etc.).
Make sure to checkout our article on common data discrepancies to understand why your conversions look different between Google Ads & GA4.
Step 9: Custom Reports
Finally, if there’s any custom reports your organization will need on a regular basis, they should be setup early on to ensure they populate correctly. There’s two ways to create a custom report in GA4 – you can either customize an existing report or you can create one from scratch using Explore.
Detailing how to create custom reports in Explore would require another 10 steps to explain. In the meantime, checkout this guide by MonsterInsights.
Thankfully creating a custom report from an existing report is simple. All you have to do is click the pencil symbol in the top right to begin customizing the dimensions, metrics, filters, chart types etc. You can then save the customized report as the default or as a new report.
We also recommend checking out Krista Seiden’s article on how to make a custom GA4 report in ~30 seconds. And please note that the Realtime report can’t be customized as of this writing.
Step 10: Audits & Ongoing Maintenance
We recommend regularly auditing your GA4 setup and investing into ongoing maintenance. The frequency of audits and maintenance should be determined by your website’s business value. For example, S&P500 companies should probably be investing in doing monthly or quarterly audits for their primary websites whereas SMBs could probably do annual checks. This will also vary greatly based on industry (e.g., ecommerce will likely need more frequent checks and maintenance).
We hope you found this Google Analytics implementation guide helpful, but please feel free to contact us today if you need assistance implementing Google Analytics 4. Our GA4 certified professionals are on standby!