Google Analytics


Google Analytics is the recommended tool to track user interaction and collect basic data from your website.

A Template Site can be tracked by Google Analytics. If you want to learn more about Google Analytics, visit the University's Lynda.com training website (login required) and search for "Google Analytics Essential Training." You can also follow their instructions titled "Get Started with Google Analytics".


Step 1: Choose a Google account to log into Analytics

You will need a Google account to use Google Analytics. Your options for obtaining an account are:

  • Recommended: Use a Service Account. Signup for a new account or use an existing one. Make sure the account is enabled for Google Apps. Move on to Step 2. The advantage of using a service account is that the account is not decommissioned when an individual leaves the University.
  • If you already have a Princeton University Google account, and you would like to use that account, you are welcome to do so. Make sure the account is enabled for Google Apps. Move on to Step 2.
  • If you would like to create a new non-Princeton Google account for only this purpose, you can do so for free at https://www.google.com/accounts/NewAccount then move on to Step 2 below.

Step 2: Get a Google Analytics tracking ID (UA number)

  1. Visit analytics.google.com to log in (or register if this is the first time using Google Analytics with this account). 
  2. Once you are successfully logged in you will need to follow these instructions to set up a property and generate your tracking ID.
  3. This tracking ID is part of the tracking code that is inserted in the source code for your site.  The tracking ID, sometimes called a 'UA number' will appear something like "UA-12345678-9." Copy this number.

Step 3: Add the UA number to your site

From the Admin menu, select the Configuration option and click Google Analytics on the right-hand side under System.

Analytics image

Paste/Enter your Web Property ID number. 

Analytics image

After the number has been added and Google has indexed the website, you can log in to Google Analytics to start seeing the statistics for your website.


Analytic reporting

Once Google Analytics and your Drupal website are linked properly, learn to create dashboards and reporting mechanisms in Google Analytics. Common metric reporting can be done on Page Views and Visits.

If you want to see results on a specific page within your website, click on Behavior, and then All Pages

Google Analytics image

Use the Page Title option to find your page

Google Analytics image

Use the Show rows: option to alter your view

Google Analytics image


Troubleshooting

Make sure the PWDS Analytics feature is enabled in your Drupal administration options. From the Structure option in the Admin menu, select Features.

From the menu on the right, select PWDS. Make sure that PWDS Analytics is enabled in the check box.

Analytics image


How to Recover a Google Analytics Account

Please Note: WDS does NOT keep track of your user name and password to access your Google Analytics account. It is your responsibility to manage this information. If you have staff turnover, please be sure to transfer this knowledge accordingly.

External Resources:


Related Links: