Google Analytics
Last updated
Last updated
This guide provides a step-by-step process for setting up Google Analytics 4 (GA4) on your website, including how to integrate tracking in compliance with GDPR requirements. You'll learn how to create a GA4 property, find and use your Measurement ID, and configure your tracking code to activate only after user consent is given. This document also explains how GDPR compliance may impact data accuracy due to cookie consent restrictions.
For additional support, refer to these helpful resources:
Go to and sign in with your Google account.
Click on Admin in the lower-left corner.
Under Account, select Create Account and follow the prompts to set up your account name and configure data sharing settings.
After creating the account, click Create Property.
Enter the property name, select the reporting time zone, and currency.
Follow prompts to configure business details, then click Create.
In your GA4 property, go to Data Streams and select Web.
Enter your website URL and a stream name, then click Create Stream.
In the stream details, locate the Measurement ID at the top right (it starts with "G-").
Copy this Measurement ID — you’ll need it to set up tracking on your site.
Open Wavecast Publishing to your Settings > Analytics page.
Paste in the Measurement ID in the Measurement ID input field.
In the <head>
section of this page, paste the tracking code.
Modify the code by adding data-cookieconsent="analytics"
to the script tag if you're using a cookie consent solution. The updated tag should look like this:
Save and publish your changes.
To accurately track user interactions across different devices and sessions, you can enable User-ID in Google Analytics 4. This feature allows you to gain deeper insights by associating multiple events and sessions with a unique, persistent ID for each user.
IMPORTANT: Before implementing User-ID on your website, you must first enable User-ID in your GA4 account settings. Without enabling it, User-ID tracking will not function as intended.
If you are implementing Google Analytics, you must ensure compliance with EU GDPR laws.
To comply:
Use a cookie consent management tool that allows users to accept or reject cookies.
Ensure that analytics tracking only activates after the user has given explicit consent.
Clearly communicate in your privacy policy how Google Analytics is used and what data is collected.
This means that you are required to implement a to inform users and obtain their consent for data collection.
Due to these regulations and the requirement for cookie consent, your Google Analytics data may not be fully accurate. Find out more about and how affect website analytics.
Note that the hub provides some information about and . This is GDPR compliant, as rather than tracking the user, we are analysing the pages themselves instead and, where applicable, have anonymised the data.
YOUR_MEASUREMENT_ID
with the actual Measurement ID you copied in Step 3.