Whenever you build a new website it’s a great idea to to make sure to add Google Analytics or Google Tag Manger.  Divi makes it super easy to add Google Tag Manger 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 Manger 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,

Google Tag Manager Container Name

Click on the Google Tag Manager GTM Link to get the Tracking Code

Google Tag Manager GMT Code Link

Click on the Google Google Tag Manager GTM link to open up the Tag Manger header and body code snippets.

Google Tag Manager Tracking Code For Header and Body

  • 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>”.

Adding Google Tag Manager to your Divi Theme

  • 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