#StudioPress: Setup Google Analytics Code with StudioPress Genesis and child theme!

http://PressSavvy.com – Hundreds of FREE WordPress Training Tutorials. Updated Constantly!

SUBSCRIBE NOW to get the latest WordPress Tutorials.

MORE VIDEOS! I will be creating new training videos constantly so subscribe to this channel and don’t miss out.

I’M STUCK? No worries, post your question as a comment and I will reply right away.

CAN YOU HELP ME? Of course, submit your request here: http://presssavvy.com/request-training/

Google Analytics is a free service that provides site owners with detailed information of how visitors interact with their site. It provides useful data on measures such as the number of people visiting, their country of origin, the pages viewed, average time spent on the site, whether the visitor is new to the site or returning and much more.

In this post I will show you how to set up a Google Analytics account and how easy the process is of adding Google Analytics code to your Genesis Theme.

However, before you can use Google Analytics you first need to set up a Google Account. Once this account is set up you gain access to other free tools such as Webmaster Tools which I also use.

If you already have an Analytics account and just want to know how to add the Analytics code to your Genesis Theme, then click here to jump straight to that section.

How to Set Up Google Analytics

Log in to Google Analytics and click on the following sign up button.

Google Analytics log in

Next you need to complete the following form. I have explained each point below the screenshot.

1. Select “Website”.

2. Select either “Universal Analytics” or “Classic Analytics”.

I personally use “Universal Analytics”. Here are a couple of quotes from Google that influenced my decision to use this version:

“Our goal is to enable Universal Analytics for all Google Analytics properties. Soon all Google Analytics updates and new features will be built on top of the Universal Analytics infrastructure. To make sure all properties upgrade, Classic Analytics properties that don’t initiate a transfer will be auto-transferred to Universal Analytics in the coming months.”

“All Google Analytics properties will soon be required to use Universal Analytics. Any properties that don’t follow the upgrade process will be auto-transferred to Universal Analytics in the future.”

3. Give your account a name and enter the details of your site.

4. Use the dropdown to select a category that relates to your site.

5. Use the dropdown and select your time zone.

6. Select or deselect your data sharing settings preferences.

7. Click “Get Tracking ID” after which a “Google Analytics Terms of Service Agreement” will pop up which you will have to accept to proceed. Once accepted you will be taken to your “Traffic Code” page which contains your Google Analytics tracking ID and tracking code as shown below.

Where to Add Google Analytics Code in a Genesis Theme

Log in to your WordPress dashboard. Select “Genesis” “Theme Settings” and scroll down to “Header and Footer Scripts” then copy and paste your Google Analytics Tracking code into the box shown below. Now save your settings and that’s it done.

After completing the above you can check the status of your tracking by going back to your “Traffic Code” page, shown earlier in this post, and refresh the page to view the tracking status.

If you have closed the page here’s how to access it:

Log back in to your Analytics account and click on “Admin” in the top right corner, you will then see the screen shown below. Click on “Tracking Info” and select “Traffic Code”.


21 Responses

  1. Alfonso Pacheco

    Should I add this code to every single post or PAGE that I create or just by adding it to the Genesis Theme, it takes care of anayzing the whole site? Thanks btw! Really awesome video. I have recommended it to all the guys I know who are creating new sites.

  2. Heather Carter

    Hi Derek. Great video, it's very helpful! Question: I added a SSL Certificate to my site, which changed my domain and links to "https". Do I need to add the new tracking code from Google to my WordPress site? I'm using the Magazine Pro theme. If yes, will it effect my ranking and page views when adding the new tracking code? Thank you so much! ~Heather @https://mysweetmission.net/

  3. Pip Seymour

    haha thanks.. that was so easy.. and Now I can continue on with what I was trying to learn 🙂 thank you for making that simple, and quick

  4. Paige Strand

    Hi there, I just wanted to clarify that in doing this action once, this works for all pages? I would have assumed this needs to be done for each specific page, and I'm shocked by how simple this really is lol. Thank you for simplifying this, I really appreciate it.

  5. fabrixx2

    Thank you, i swithc to studiopress I had forgotten to reput analytics code, its very simple..I have not put his hand to the editor this time

  6. Chris H

    Thanks for the fast & simple instructions on installing Analytics in my Genesis WP site.
    Greatly appreciated!

  7. Ryan Jacobs

    Ok, so I thought I had it, but I'm at a loss. I followed the instructions to a t, but GA still says "Tracking Not Installed". I have also tried to deactivate all plugins and refresh, and clear the cache through the GA plugin. Any suggestions? Thanks!

  8. Lauren Silva

    Hi, thanks for this. Just tried installing our code, but GA still says Tracking Not Installed. Is there a lag time for data to start showing? I tried logging in and out of my google account but it is not refreshing. It may be worth mentioning that the site is not a .com, but rather a .solutions URL – not sure if this could have an effect. Also, we have this in the header script as well: <link href="//maxcdn.bootstrapcdn.com/font-awesome/4.1.0/css/font-awesome.min.css" rel="stylesheet">

  9. Mikki

    Thank you!! I had been driving myself crazy trying to figure this out. I just started with a Genesis theme and I'm still learning! Thanks!

  10. Daniel Euergetes

    I want to thank you for this!  I have the Genesis Theme and bashing my head against the wall trying to get it onto the theme's header.php file.  Of course, I was met with "Do NOT under any circumstances, edit this file!  Go to child theme instead."  Well, no header.php file there, so this really looked bureaucratic to me LOL!

    This bit of information was extremely helpful!