AnalyticsSetup

From Admob For Developers

Jump to: navigation, search

Contents

Analytics Setup

Welcome to AdMob Analytics. This installation guide will walk you through setting up your account, installing the code, and help you get started. There are five basic steps to setting up analytics and tracking on your site.

1. Create Your Account

  1. Visit analytics.admob.com
  2. If you have an existing AdMob account for accessing www.admob.com, use it to log in and skip to Step 2.
  3. If you do not have an existing AdMob account, click "Get Started" to create one.
  4. Fill out relevant information and click "Submit".

2. Download the Analytics Code

  1. Login to your Analytics account.
  2. After you have logged in, click Add Site. If you are an existing AdMob publisher and are serving ads, your site has already been created. Click Edit next to the name of your mobile site to retrieve the source code.
  3. Enter the name of your site, your site’s URL, and the category that best describes your mobile site. Enable Benchmarking if you want to participate in site benchmarking when it is available. Click Add.
  4. Pick the language of the Analytics code that works with your mobile site and copy the code. Available languages: PHP, Java 2 SE 1.4, Java 2 SE 5, C#, CGI/Perl, Ruby on Rails, VB.NET, Visual Basic, and Static HTML. Note: The Static HTML option lacks many key features and is not recommended for analytics tracking.

3. Install the Analytics Code

  1. Place the Analytics code anywhere between the body tags in your mobile site's source code. You can also place the publisher code in its own file and include this file where necessary.
  2. Enable session tracking
  3. Configure cookies to improve unique user tracking and visitor identification.

4. Configure Your Request

The code supports both AdMob Analytics requests as well ad serving. When you download the Analytics code, it is configured to only make Analytics requests. Unless you want to serve ads, you do not need to change the parameters in any way.

Configuration Parameters

Parameter Data type Default Value Notes
PUBLISHER_ID String Leave blank. Publisher ID required for ad serving only
ANALYTICS_ID String Your analytics id A unique Analytics ID (e.g. 'axxxxxxxxxxxxxx') is automatically generated for each mobile site when the site is created. If you create two mobile sites within a single Analytics account, each site will have a unique Analytics ID.
AD_REQUEST Boolean False Only set to true if you want to enable ad serving
ANALYTICS_REQUEST Boolean True Set to true to enable analytics
TEST_MODE Boolean False Used to test ad requests. Set to false for analytics requests.


Optional Parameters

There are also two optional features available in Analytics: page title and event tracking. To use these features you need to pass the corresponding optional parameter ("title" or "event") in your analytics request. These parameters can be passed on some or none of the pages. Many users set up these parameters to customize Analytics for the site's specific business objectives.

Title

The optional "title" parameter is used to name mobile pages as they appear in the output in the Analytics interface. In Analytics, you can view top content pages by URL or by Page Title. Viewing Top Content by page view enables you to grouping similar pages together and track the performance across different types of pages. For example if you operate a mobile downloads site, you might be interested in comparing how users behaved on "Video" pages versus "Photo" pages.

Below is how the "Video" Page Title would be passed in PHP:

$admob_params['OPTIONAL']['title'] = "Video";

Event

Event Tracking allows the user to highlight specific pages that are key to the measuring the success of the mobile site.

Below is how the "Registration" Event would be passed in PHP:

$admob_params['OPTIONAL']['event'] = "Registration";

5. Activate Analytics

  1. Load a page on your mobile site with the Analytics code installed.
  2. If the code is properly installed, your site will be activated and the status will set to "Active" on the Analytics site list page. Activation should take no more than 30 minutes from the time we receive the first request from your site.
  3. The Analytics account owner will receive a notification email that the site has been activated
  4. Data will populate in the Analytics Dashboard within an hour of receiving the notification email. Full data will be collected and will be available within several hours. Note: need to change the custom data range to include the current day if you want to view intraday statistics.
Personal tools
Documentation