Welcome to the greatest non-productive activity in the history of blogging: Google Analytics.
I call it Google Analytics for two reasons: one, because that’s the official name, and two, because Google has rejected my repeated suggestions to change it to something much more honest, such as Blogger’s Time Toilet.
Anyway… you wouldn’t be here if you weren’t planning on adding this highly addictive, yet necessary tool to your blog, so let’s get on with it.
Google Analytics will let you see how many people are visiting your blog and where they came from. You’ll also have the ability to run all sorts of other important data which we’ll get into in another post. For now, we’re just going to focus on the installation.
In a previous post I explained how to setup Google Webmaster Tools. That’s kind of important if you plan on showing up in Google’s organic search results and improving your ranking, so if you haven’t followed along with me on that one yet you should probably go do it before you continue.
Alright, there are several ways to install GA on your blog. You can either use one of the many WordPress plugins available, or do it the right way and simply paste some code on your site and be finished with it in 10-minutes.
I know there are a lot of highly respected bloggers and experts out there singing the praises of their favorite plugin, but I am here to go against all of them.
In my book, any time you can reduce unnecessary bulk and load time to the backend of your site the better. Not to mention every one of these plugins grant 3rd-party access to your data. Also, a lot of them are feeding ads into your statistics.
Look… I know it’s convenient to see your stats right on your WordPress dashboard, but they don’t give you the full picture anyway.
As you can imagine, I’ll only be covering the manual installation of Google Analytics in this post. If you want to go the plugin route, go try and sift through the complicated, authentication process for your chosen plugin.
OK, the first thing you’ll need to do is have an active Gmail account. I know, it sucks they make you do that, but if you want access to everything Google offers, it’s a requirement.
If you have that, then the next step is to actually sign-up for Google Analytics.
Next, they’re going to put you through some basic questions about your site. They’ll want you to give your site an account name (which is how you’ll identify this particular site in GA), the name of your website, the web address and whether or not it’s a website or a mobile app (hint: it’s a website).
Click on the Get Tracking I.D. button and accept the service agreement.
If you’ve got all that finished it’s time to simply grab the code and paste it into your blog.
Since I use the Genesis Framework for my theme I have easy access to header and footer code placement (it’s at the bottom of the Genesis theme settings). If you’re not using a theme with that support, it’s a simple matter of downloading and installing the Insert Headers and Footers plugin.
Note that this is NOT one of the bulky, intrusive, GA plugins I mentioned before, this is a simple, light-weight plugin that won’t bog down your site one bit. All it does is make it easy for you to place code in the header and footer, and that’s what you’ll need to do to get Google Analytics to work.
Are you still with me? Good.
So, copy the code supplied by Google Analytics in the first box. Ignore everything else, it’s just there to confuse you.
Now, get into the backend of your WordPress site and paste that code into your “Header” box. You’ll find that in either the Genesis theme settings (if you’re using Genesis) or if you’re using the Headers and Footers plugin you’ll need to find the link in the left-hand sidebar.
Obviously, if you’re using some other theme supporting code placement, go there instead.
Click “save” and you’re done.
All that’s left now is to log into Google Analytics and check to make sure it’s recording your site’s visits.
Open another browser tab and go to your website then click back on the GA tab in your browser and take a look.
If everything is set, you should be able to click on Real-Time >> Overview and it should indicate the number of visitors on your site (which should be any number other than zero).
If you don’t see anyone there, make sure you’re actually on your site in another tab.
Well, that’s all there really is to installing Google Analytics on your site.
Good luck!