Is the Google Analytics Integration Not Working for Your Webflow Website?
Dec 7, 2023
I recently had a client email me because they were having trouble integrating Google Analytics with their new Webflow website I built for them.
Webflow has a native Google Analytics integration where you can just enter your Google Analytics Tracking ID and click 'Save Changes' and 'Publish':

Seems easy enough right?
Well, here's where the confusion lies and the problem my client was having; this integration is only for Universal Analytics, which is a specific version of Google Analytics. You can tell by looking at the tracking ID. It starts with "UA".
What's wrong with that?
Well if you go create a new Google Analytics account for a new website today, you don't get Universal Analytics. You get Google Analytics 4 by default, which is their latest iteration of Google Analytics and it has a different type of tracking ID.
You'll recognize a Google Analytics 4 tracking ID because it starts with "G" instead of "UA".
To install Google Analytics 4 into Webflow, you'll simply copy the script and paste it in the Custom Code section of your Webflow site.
You can find the Google Analytics 4 script in the admin area. Click on the gear icon in the bottom left corner of the screen and then click on 'Data Streams':

Click on the Data Stream for your website:

Next click on the dropdown arrow to reveal the script:

Then you'll find the script for installing on your Webflow website. Go ahead and copy that to your clipboard:

Then paste:

Hit 'Save Changes' and 'Publish' and you're good to go!