Below is a step by step guide on installing Google Analytics on your website
The first thing you need is a Google Account. Go to analytics.google.com to get started.
1. In the upper right, there is a button that says “Access Analytics.”
a. If you have an account: click on that button and sign in.
b. If you do not have an account: just below that button, there is a text link which reads “Sign Up Now.” Click that link and proceed to register. Then go back to the “Access Analytics” button on the Google Analytics home page and click that button to enter.
2. Google will then provide you with a prompt that says “Add New Account” Depending on whether or not you have already started to set up analytics before, this button may either be right in the middle of the screen at a prompt or in the upper right-hand corner at the top of a gray and white table.
3. A new page will then pop up that says “Sign Up.”
4. You will then see a page titled “Analytics: New Account Signup” – Fill out all of the following information:
a. Website’s URL – Your websites address
b. Account Name – Anything you want – Either use the site address or simplify it.
c. Time zone country or territory:
d. Time Zone:
e. Click “Continue”
5. Page 2 of “Analytics: New Account Signup” asks for your contact information:
a. Last Name
b. First Name
c. Country or Territory
6. Page 3 of “Analytics: New Account Signup” displays the Terms of Service for you to read and agree to. Check the box that says “Yes, I agree to the above terms and conditions” and then click the button on the bottom left that says “Create New Account.”
7. The next page is titled “Analytics: Tracking Instructions.” Code that looks something like this will appear in a box on the page:
var _gaq = _gaq || ;
8. This code needs to be installed on every page on your site. Depending on your web site there are a few ways to do this. Please continue to the applicable section below based on your type of website.
Joomla! – Go to “Extension Manager” and select “Template Manager.” Click on the default template and then select “Edit Html.” Scroll to the bottom of the code on the page and just before the (/body) tag paste in the Google Analytics code and select “Save.” This will install the code automatically on every page of your Joomla! site.
WordPress – Install one of the many Google Analytics plugins for WordPress. We typically prefer to use Google Analytics by Yoast. Login to your WordPress control panel, click “Plugins” then “Add New” and search for “Google Analytics.” After installing the plugin, you will have to configure it for your account. You will need your unique analytics key which looks like this: UA-XXXXXXXX-X. Save the configuration.
Standard HTML – You will have to edit each “index.html” page on your site in every directory by adding the Google Analytics code just prior to where the HTML code says (/body)
9. To make sure that you installed analytics properly find the site you just added on the table displayed by Google Analytics in your admin panel and click the “Edit” text link.
On the next page in the upper right, click the link that says “Check Status.” -> The next page should tell you “Analytics has been successfully installed, and data is being gathered now” under the “Tracking Status:” section in the top yellow box. If the “Tracking Status” does not say Analytics has been installed properly go back and reinstall the code according to your website configuration.