Whenever you build a new website it’s a great idea to to make sure to add Google Analytics or Google Tag Manager. Divi makes it super easy to add Google Tag Manager to your Divi theme. The advantage of using Google Tag manager script over simply adding a Google Analytics script, is once the Tag Manager script is added, you can then add scripts for things like Facebook Pixels and other scripts you might find useful without having to add the to the website directly.
Here are the simple steps to install Google Tag Manager tracking code on your WordPress website using a Divi theme.
- Step 1: You need to get the setup a Google Tag Manager Account and get the Google Tag Manager tracking. (See Setting Up Google Tag Manager).
Note: If you have already setup Google Tag Manager for the website, simply log into your Google Tag Manager account, click on the “Container Name” and choose your website. A GTM (Google Tag Manager) link should display in the upper right. Click on that link and copy the website tracking script that is provided,
Click on the Google Tag Manager GTM Link to get the Tracking Code
Click on the Google Google Tag Manager GTM link to open up the Tag Manager header and body code snippets.
- Step 2: Log into your website’s WordPress admin “yourdomain.com/wp-admin”.
- Step 3: Select Divi –> Divi Theme Options (Integration) tab (Note: You can also do this for the Extra Theme as seen below)
- Step 4: Paste the copied Google Tag Manager Tracking Code information into the 2 sections that say “Add code to the < head >” and “Add code to the <body>”.
- Step 5: Check that you have setup the Google Tag Manager has been setup correctly by using a Chrome Extension called Google Assistant. It will validate and tell you what Google scripts have been implemented and if they are active.
After you added your Google Tag Manager to your Divi Theme, I have written another really cool article to make your Divi Blog Pop.
Rather than having the boring Divi out of the box blog, you can create a Divi Magazine Blog Layout.
Divi Magazine Blog Layout
The body tag constantly breaks my site, so I couldn’t integrate that. Any solutions/ideas on how to resolve that? Thank you.
Make sure your DIVI & WordPress Install are up to date. 9x out of 10 this will fix the problem.
If not, disable plugins one by one until the problem is resolved. It could be related to an SEO plugin.
Good luck John!
Thanks Tom for this resource!!
Thank you very much, It worked 🙂
I had the FTP client opened but when I saw your post, I was able to close it for goind into the Divi theme options 🙂
Thanks again, Côme