Site statistics play an important role in traffic analysis and success of your website. Google Analytics is a free tool from Google which can keep track of your site traffic by just embedding simple code in your website/WordPress. There are ready made plugins available to serve this purpose. We will discuss the importance of Google Analytics and how to install one for your WordPress site in this article.
What is Google Analytics?
Google Analytics is the enterprise-class web analytics solution that gives you rich insights into your website traffic and marketing effectiveness. Powerful, flexible and easy-to-use features now let you see and analyze your traffic data in an entirely new way. With Google Analytics, you’re more prepared to write better-targeted ads, strengthen your marketing initiatives and create higher converting websites. -From Google Analytics Website
You can see your website traffic as well as visitors geographical locals, browser types, pages they visits, etc. Basically you can get the answers of the following questions.
What they do when they are on your website?
You can track what visitors are looking in your site, like pages they visit and navigate through your site. How long they visit these pages and where they are coming from (directed by or to) or how they are exiting your site. Who are your regular visitor and who are new to your site. All these answers will help to shape your website and make it more better to attract more visitors and retain those who visit regularly.
How they interact with your site’s content?
Google Analytics also show how visitors interact with your site- that means what they click, the link they follow and what percentage of visitors click what. All these answers will help to shape your traffic.
Where did they arrive on your website from?
If you are working as SEO for website, then you must know which search engine your visitors are using to reach your site. Percentage of traffic send by each search engines and keyword used to reach your site are crucial information you need. Google Analytics will give you breakdown of each items which will help you to optimize your site.
After analyzing the benefits, lets move to installing Google Analytics to your WordPress Site. Follow the steps mentioned below and will find it easy to achieve what you are looking for.
Create or Sign In Google Account
Before you include Google Analytics to your website, you should have valid Google Analytics account. You can use gmail account for this if you have one. Go to Google Analytics | Official Website sign up for free.

Google Analytics Login Page
Once you have sign in successfully you will be prompted to the screen as shown below. Look at the top right hand side drop down box, click and select Create New Account.

Create New Account
You will be prompted with the screen shown below. Click Sign Up button

Sign Up
You will be prompted to fill the form with required information as shown below.
Click Continue button and finish the form by supplying required information. At the end you will be prompted with tracking code which you can embed in your site. Read rest of the article how and where to use this code.

Tracking Codes
How to Add Google Analytics Code to WordPress Site.
Once you have created Goggle Analytics account and Signed Up for the tracking code. You can now add the code to your site in three different ways:
1. Direct Paste Method
Copy the code that you received in Sing Up process above, and paste it in your theme’s footer.php right above the </body> tag. Below figure shows the location of footer.php using FileZilla ftp client program.
You can modify the footer.php file using any php editor or software like Dreamweaver and upload it to same location, as shown below. You can also use WordPress Admin panel>Appearance>editor to modify footer.php and insert the code at location shown below.

footer.php file
2. Functions.php Method
Add the following code in your theme’s functions.php file and don’t forget to paste your Google Analytics code from above here.
<?php
add_action(‘wp_footer’, ‘add_googleanalytics’);
function add_googleanalytics() { ?>
// Paste your Google Analytics code here
<?php } ?>
3. Plugins Method
There are many plugins available to add Google Analytics to WordPress site. You can easily search them in WordPress Plugin Directory. The two that we recommend are:
Google Analytics for WordPress by Joost de Valk
Google Analyticator by Ronald Heft
Installation steps are included with these plugins.
Once you have installed Google Analytics successfully on your website, Google will start tracking your site. You can Sign In to your Google Analytics account and view the traffic statistics whenever you like.