An Introduction To Google Analytics For WordPress

Last Updated on January 2, 2023 by 38 Comments

Editorial Note: We may earn a commission when you visit links on our website.
An Introduction To Google Analytics For WordPress
Blog / Resources / An Introduction To Google Analytics For WordPress

Google Analytics is a web analytics service that was launched by Google in 2005. The regular service is free to use, however Google also offers a premium option for companies.

I have been using Google Analytics on all of my websites since it was first launched. The service is easy to use, though it also offers a lot of advanced features for experienced web developers such as conversions and goal tracking.

Today I would like to show you what the service offers and how it can help you analyze the traffic you receive to your website.

Installing Google Analytics on Your Website

As with all Google services, you need to have a Google account in order to use Google Analytics. After you have logged in, you will be see four links in the top navigation menu: Home, Reporting, Customization and Admin. Click on the admin link.

Google Analytics Home

The admin area allows you to configure all of the websites you are tracking.

The center column is for properties. At the top of the column you will see a drop down menu that allows you to switch between menus. At the very bottom is an option to create a new property. You need to click on this to track a new website.

Create New Property

Clicking on โ€œCreate new propertyโ€ will take you to track another website.

There are two different tracking methods available. Universal Analytics is the new standard way of tracking by Google and the one I recommend choosing. Classic Analytics is the old tracking method that they used for several years.

New Property

Choose Universal Analytics as it provides more data about your website.

Setting up a new property will only take you a minute. You simply need to enter your website name, URL, industry and your preferred timezone for your reports.

Setting Up Your Property

You only need to enter basic information about your website in order to get started.

Google will then provide you with your Javascript tracking code. This code should be placed just before the closing </head> tag of your website. In regular WordPress themes, you can create a child theme and add the code to your websiteโ€™s header.php file. WordPress frameworks and advanced WordPress themes normally have an option to add Google Analytics code in the settings area โ€“ in our Divi theme, for example, you can use the Integration Tab in ePanel. You can also use a plugin, such as Google Analytics For WordPress, which will automate the process for you.

Google Analytics used to be known for slowing down web pages, however Google now uses asynchronous loading to ensure that the tracking code is not executed until the page has already been loaded.

Google Analytics Tracking Code

Add your Google Analytics code just before </head>.

Another page that you will find useful within the admin area is User Management. This page allows you to to add permissions to view and edit your website reports for other people. Up to four permissions can be chosen: Manage Users, Edit, Collaborate, and Read and Analyze.

Google Analytics User Management

Staff and admin can be allowed to view and edit your Google Analytics reports.

Once you have installed your website, you will see it listed in the Google Analytics home page with the other websites you track.

Google Analytics Website List

Every website you track can be found on the Google Analytics home page.

Google Analytics Reports

The reporting area is where all of your main reports are located. The page is divided into several different categories. In this section, I would like to give you a brief introduction to each one and explain what they offer.


Google Analytics offers dozens and dozens of pre-made reports. The dashboards section allow you to build a page that displays any report you want.

Google offers a starter dashboard to get you started. It is a great way of seeing how dashboards work and seeing what is on offer.

Create Dashboard

Google lets you to choose from a blank canvas or a pre-made canvas that features popular reports.

The blank canvas option allows you to start from scratch and create your own custom report. It is a great way of customising your dashboard so that the reports that matter to you are displayed.

Google Analytics Dashboards

Dashboards allow you to tailer reports to your needs.


At the top of every Google Analytics report is a menu that features customization and export options. The menu is different on some report, but the menu always includes an option to add a shortcut to the report.

Shortcut Link

Add a shortcut to your favorite report.

This menu also gives you the option to email a report to someone, add the report to your dashboard, and download the report in one of six formats.

Google Analytics Tabs

Google Analytics reports can be downloaded to your computer or emailed to an associate.

When you click on the shortcut link, Google gives you an option to change the name of the shortcut.

Add Shortcut

You can rename the shortcut if you wish.

Whereas dashboards allow you to display several reports on one page, shortcuts simply link to selected reports. It is essentially a way to list the reports you use all the time.

Google Analytics Shortcuts

Shorts are a good way of quickly navigating to the reports you use frequently.

Intelligence Events

Intelligence Events is an option in Google Analytics that allows you to track daily, weekly or monthly events. It allows you to track a wide range of events such as page views, clicks, visits, bounce rates, sales conversions, and more.

Google Analytics Weekly Events Example

Intelligence Events allow you to monitor just about anything.

It only takes a minute to add a new alert. You can apply alerts to all your traffic or select something specific. For example, you could set up an alert specifically for a certain landing page you have just created.

There are dozens of targets to choose from and you have full control over the exact value an alert should be trigged. All alerts will be displayed on the Intelligence Events page. Alerts can be emailed to you as well.

Create an Alert

Alerts are available in five different categories: Site Usage, Goals, E-Commerce, Content, and Clicks.


Real-Time reports give you a live report about visitors who are currently on your website. There are five Real-Time reports to view: Locations, Traffic Sources, Content, Events, and Conversions.

The overview page highlights the number of visitors viewing at the moment. Per second and per minute graphs also detail visits over the last thirty minutes. Top pages, top referrals, top social traffic and top content are also displayed.

Real-Time Reports

Real-Time reports are useful if you are experiencing a spike in traffic. I love to view the report after sending out an email blast to newsletter subscribers.


There are over a dozen audience reports on offer including reports on demographics, location, and the devices visitors are using to browse your website. It offers so much more than just visits and page views.

The Audience reports essentially tell you who your visitors are. For example, it advises you whether someone is a return visitor, the language of the device they are using, their age, and their gender. It will also tell you about their interests.

Audience Reports

Audience reports will give you a better understanding of who your audience are and how they are viewing your website.


Whereas Audience reports give you information about your visitors, Acquisition reports advise you where those people came from. It includes a wide range of reports including channels, referrals, paid search engine traffic, and organic search engine traffic.

It also breaks down social media traffic and provides information on search engine keywords and landing pages. Google Adwords is also integrated into this section.

Acquisition Reports

Acquisition reports will help you see exactly where your traffic is coming from.


Behaviour reports give you information about what visitors are doing once they are on your website. It includes reports such as landing pages, exit pages, on site searches, and site speed. Google Adsense is also integrated into this section.

Behaviour Flow is one of my favorite reports. It is a visual report on what your most popular pages are and what pages visitors are navigating to afterwards.

Behaviour Reports

Behaviour reports will give you a better understanding of what visitors are doing when they are on your website.


Conversions reports offers many reports for online shop owners including product performance, sales performance, transactions and time to purchase. Sales funnels can also be shown.

This section also allows you to create goals and then monitor them. This can be used to track anything from an email subscription to downloads of specific files. These features are flexible, but it will take you a while to understand it fully.

Conversions Reports

Conversions reports allow you to track a wide range of goals, sales and conversions.

Custom Reports

Google also gives you the option to create custom reports. Dozens and dozens of metrics can be chosen for your reports.

Custom reports are beyond the scope of this article, however you should keep them in mind for the future incase you need to track something unique on your website.

Custom Reports

Custom Reports allow you to create unique reports that display whatever metrics you want.

I hope you have enjoyed this introduction to Google Analytics. If so, I encourage you to subscribe to the Elegant Themes blog so that you are always kept up to date with our latest articles ๐Ÿ™‚

Article thumbnail image by Elena Kalistratova /


Want To Build Better WordPress Websites? Start Here! ๐Ÿ‘‡

Take the first step towards a better website.

Get Started
Premade Layouts

Check Out These Related Posts

9 Non-Profit Child Themes for Divi

9 Non-Profit Child Themes for Divi

Updated on January 23, 2023 in Resources

There are lots of nonprofit organizations across the globe. Just about every one of them needs a well-designed website to tell their story and receive donations to help their causes. Divi is an excellent theme for nonprofits such as charities. Fortunately, you donโ€™t have to start from scratch for...

View Full Post


  1. Excellent post Kev!
    Thanks a lot.

  2. Hi, thanks for the great guide!
    How can I verify that the code is working?

  3. I am using to add analytics to my new blog but it is not working from last many hours where as I am using analytics on my various other blogs too and there the problem like this never occured

  4. In the article you mention the analytic code should go just before the tag or use the ePanel integration. But in the ePanel it says the code should be place in the “Add code to the (good for tracking codes such as google analytics)”. Which is it?

    • It depends what version of the Google Analytics code you are using. In this post, the code used should be placed in the area mentioned.

      • So just to be clear that would be the “Add code to the head” of the ET’s ePanel.


    • The form stripped out the tags.

      In the article you mention the analytic code should go just before the tag closing head tag or use the ePanel integration. But in the ePanel it says the code should be place in the โ€œAdd code to the body tag (good for tracking codes such as google analytics)โ€. Which is it?

  5. Would love to see a piece on CDN’s

    • Good suggestion. I will add that to our list of suggested posts. ๐Ÿ™‚

  6. Finest article for Google analytic, didn’t know such deep options of Google Analytic, Thanks for share Kevin

    • You’re welcome Dipak.

  7. I do appreciate the info here but when you open with “The service is easy to use” then bombarded the post with all sort of information it kind of makes me go wt# !

    I was using StatCounter but now that Keywords are being blocked that service isn’t good for keyword research. Still excellent for other stats.

    At the end of the day I’ll eventually adapt to goggles way of doing things as a puppet does.

    Cheers ๐Ÿ™‚

    • Hi Chook,

      Google Analytics is no good for keyword research either as Google has deliberately hidden the keyword information from website owners (called “secure search”, most of the keywords are now “not provided”). Bing is currently working on the secure search feature. Soon, we will not be able to do website researches with analytics.

      If you would like to do keyword researches for free, you are advised to use the “search queries” of the Google Webmaster Tools (โ€Ž) which shows the number of times your website shows up and is visited by the visitors in Google search.

      There are also a number of paid tools which claim to provide “highly accurate guesses” on the keywords but I strongly doubt their accuracy. They are guessing after all.

    • It’s a delicate line to walk I supposed. Google Analytics is easy to use on the surface, but there is also so much depth to explore ๐Ÿ™‚

  8. Highly illustrative post and I love it! Someone here mentioned opening different gmail account and having a master account to manage them all is that move not contravening Google terms of service Kevin?

  9. Hi Kevin,

    I’m new to web design so this has been great having tutorial on wordpress and web design everyday.


    • Glad you found it useful Heather.

  10. Merci pour le tutoriel c’est sympa.

  11. Just an idea, but how about some new themes?

    • You can read about new themes in the Theme Sneak Peek category, or subscribe to that section via RSS specifically to avoid other posts.

      Kevin isn’t part of our Dev team, and his posts are not made in lieu of new themes. You can always unsubscribe to the blog if these posts are not adding value for you.

  12. Been using Google Analytics for years and years. It’s the first thing I do when I start with a new client. I also set up automatic reports for them because most don’t have a clue how to do it. The only problem is the longest they allow is 12 months. So some I redo and others I don’t unless they request it.

    • I didn’t realise they had such a limitation.

  13. Thanks for the analytics info. I wanted to chime in because while I often use the ePanel to add Analytics on my sites, I have quickly become a fan of simply creating a custom plugin to add Analytics because then my Analytics isn’t tied to one theme (e.g. forgetting to re-implement when a theme is changed, etc.). Its easy, clean and doesnt require all of the configuration or additional set up that the big plugins require.

    • Good suggestion.

      I can see why many do this. I prefer to just insert the code so that I have less plugins installed.

  14. A great article, as always in ET Blog.

    But tell me… what account of Google Analytics do you guys use on a customer website that you manage? Your own account or create a new account for every customer site?

    • I agree with Daniel.

      It makes sense to simply add customers on as users so that you can still configure everything correctly. You can always upgrade them to admin level if they stop using your service.

    • Darlan ten Caten: I recommend setting up a separate (email) account for each site and having one master account that you use to monitor them all. This offers the best of both worlds in terms of flexibility and maintainability.

      • Thank you Daniel, thats a great idea.

  15. Great Post, Kevin. Analytics is extremely important for anyone who takes their traffic, and their business seriously. I also like the behavior flow report and I often joke with clients that it is the next best thing to reading your customers minds.

    There are also a few good analytics plugins which are useful when a theme does not include a place for analytics code. My favorite is the google analyticator which can be downloaded for free from the WordPress repository. It is extremely easy to use and can be setup in two minutes flat.

    • I’ve been meaning to install a plugin like that so that I can check my traffic stats through WordPress; particularly as I deactivated the stats module in Jetpack.

      I assume that installing that will not slow down your website as it only pulls the data within the admin area to show your stats.

  16. nice write up. Thanks guys ๐Ÿ™‚

    • No problem J ๐Ÿ™‚

  17. Good work Kevin. It should be noted that UA does have some limitations at the moment.

    • Can you explain what they are Les.

      I read a couple of articles that compared UA against the classic option; though few mentioned the limitations. I imagine this is because those articles were written by non-developers like myself.

      Is it more to do with how the UA code works with other scripts?

  18. Perfect timing! I just set up 4 websites on my Analytics account.

    • Glad you found it useful. ๐Ÿ™‚

Leave A Reply

Comments are reviewed and must adhere to our comments policy.

Get Started With Divi