Hello,
For anyone still struggling with this, here are the steps you need to take:
- Go to your analytics dashboard at analytics.google.com
- Click on the bottom left Admin button
- From there click Create property
- Enter a name for your property (ex. Shopify)
- On the bottom, click Show advanced options
- Check Create a Universal Analytics property
- Enter your website
- You can select the option to create both or just the Universal Analytics (this is the one Shopify needs)
- Hit Next and copy the property the ID that starts with UA-
To give a bit more context, Google recently made an update to create by default a Measurement ID (that starts with G-)instead of a Tracking ID (that starts with UA-). Shopify only accepts the tracking ID at the moment.
Hope this helps anyone else!
Hey Nick, Thousands of Shopify user unable to install Google Analytics on their Shopify store because of the recent Google Analytics change: Have a look at the recent code:
<!-- Global site tag (gtag.js) - Google Analytics -->
<script async src="https://www.googletagmanager.com/gtag/js?id=G-XXXXXXXX"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'G-XXXXXXXXXX);
</script>
ABOVE THEY GOOGLE IS NOW GIVING - "G-XXXXXXXXX" which was previously: "UA-XXXXXXXX" ...I think this is the issue by Shopify. Shopify should consider this seriously. Thanks!
With regards,
Muhammad
The error message is Analytics snippet does not look valid (UA-xxxx-x), so I think that has some validation in the shopify's application back-end and needs to be updated, because Google Analytics is now generate a code in the format G-XXXXXXXXX and no UA-XXXX-X, I'm in 12-2020 and this error is still happening. Fortunately I found a work around to put this in the code of the theme, but can have others persons that don't have this skill.
User | Count |
---|---|
49 | |
27 | |
25 | |
23 | |
23 |