Google Analytics Services SDK

To add Google Analytics Services SDK to your Xcode project:

  1. Download the SDK.
  2. Add libraries from the downloaded SDK to your Xcode project.

Download the SDK

The Google Analytics Services SDK contains the latest Google Analytics and Google Tag Manager for Mobile libraries.

If you'd like to learn more about Google Tag Manager, see Google Tag Manager for Mobile Apps.

Version Package Size SHA1 Checksum
3.15 19.5MB 90a4dbcd3bcbb310b8a468c11a1a662395aa1e3d
3.13 6.9MB cdfa43636ea8c588bb77f93a3b0eaeddfc24d5c7

As of version 3.14 Google Analytics supports bitcode, which may cause compiler errors under Xcode 6. If you are still using Xcode 6 consider downloading v3.13.

Add libraries to your Xcode project

Add these files from the downloaded SDK to your Xcode project:

  • GAI.h
  • GAIDictionaryBuilder.h
  • GAIEcommerceProduct.h
  • GAIEcommerceProductAction.h
  • GAIEcommercePromotion.h
  • GAIFields.h
  • GAILogger.h
  • GAITrackedViewController.h
  • GAITracker.h

The Google Analytics SDK uses the CoreData and SystemConfiguration frameworks, so you will need to add the following to your application target's linked libraries:

  • CoreData.framework
  • SystemConfiguration.framework
  • libz.dylib
  • libsqlite3.dylib
  • libGoogleAnalyticsServices.a

Next steps

  • Read the Mobile App Implementation Guide to learn how to use Google Analytics to measure user interactions and answer questions about app usage.
  • Review additional configuration options such as sampling, testing and debugging, opt-out settings, etc.
  • If required by your app, enable optional features such as Enhanced Ecommerce, IDFA (Identifier for Advertisers), and iAd install campaign measurement.