How to Set Up Google Analytics in Divi (without a plugin)
In this tutorial, I show you how to set up Google Analytics in your Divi website WITHOUT the use of an external plugin. WordPress Google Analytics plugins have their uses. Case in point, if your client wants to be able to see a snapshot of their site stats and page views in their dashboard but if you’re like me, you want to limit the use of extra plugins at all costs. This is the MANUAL way to set up Google Analytics and is my preferred method. It’s lightweight, quick and easy and won’t break or get outdated like plugins tend to do.
Links mentioned in the video:
Similar Tutorials:
Recommended Google Analytics Plugins:

Ready to take your web design journey to the next level? I want to help.
Whether it's understanding the technical side of web design like Wordpress and Divi, learning the ins and outs of design, SEO and conversion, following a proven path for web design processes and systems or help with building your web design business, I have a course for you. Click below to check out my suite of web design courses and find out which one will help you level up and help you quickly become a more valuable and confident web designer!
- Josh
Josh, great info, thanks so much. Do you create a IP Address filter at the account level then for all your websites?
Thanks Peter! No I just add the site at the account level usually. Never messed with an IP filter or anything too advanced.
Great, Josh, thanks for this tutorial!
No problem. Thanks for the feedback!
Love your videos Josh. Keep up good work!
Thanks, Maciej! Much appreciated man.
Hi Josh,
In this tutorial you’ve put the Google Analytics in the body section in Divi Options. In some later tutorial, you’ve put the code in the head section. Which one is correct?
It will work in either section but it actually is best practice to put it in the head section!
Really helpful video, Josh! Thanks!
I did find one little gotcha. My tracking didn’t seem to work no matter where I put the code.
I realized after an hour or so that I had just installed a new Firefox add-on to block ads. I wondered if it also blocked Google Analytics. So I fired up a native Chrome browser. Voila! My website view count popped up to 1.
So your nifty browser extensions can block Google Analytics. Be warned! This is not a handy feature when testing. 🙂
Janet