Notification

G Suite is now Google Workspace: everything your business needs to get work done.

Google Analytics for mobile apps

Use Tag Manager with Google Analytics and Firebase.

To get the latest mobile app report features in Google Analytics, use Firebase in your Android and iOS apps. Once enabled in your app, Google Analytics will automatically collect and report on built-in events and user properties. You can also log custom events and set custom user properties.

Tag Manager for mobile apps is implemented with the Firebase SDK, and requires the creation of a Tag Manager container. Google Analytics events, parameters, and user properties are all available as configuration inputs from within Tag Manager.

Use Tag Manager, Firebase, and Google Analytics together

Apps that use Firebase automatically log information to Google Analytics. The Google Analytics for Firebase service in the Firebase SDK collects app usage data for you automatically. Reports will appear in Google Analytics as well as in the Firebase console. As long as you already use the Firebase SDK, you won't need to add any additional code to enable automatically collected events.

Add Tag Manager to your Firebase-enabled app when you need to configure additional Google and 3rd party tags.

To implement Tag Manager with your mobile projects:

  1. Get your app set up with Firebase:
  2. Create a Tag Manager account and configure a Tag Manager container.
  3. Add Tag Manager to your project (Android | iOS).

Use triggers with Event Name and Event Parameter variables to define which events should fire specific tags. Trigger conditions are evaluated whenever an event is logged in the app. Visit the Tag Manager developer documentation for Android and iOS to learn more.

Automatically collected events generated by the Firebase SDK and collected by Google Analytics cannot be modified.

Create the Google Analytics (Firebase) tag

To create a Google Analytics (Firebase) tag:

  1. Create a Google Analytics for Firebase container for Android or iOS.
  2. Click Tags and then New.
  3. Click Tag Configuration and select Google Analytics (Firebase).
  4. Use the Actions menu to modify, add, or block events.
    • Block Event: Use this option to block a manually logged event. For instance, use this if a developer accidentally logged duplicate events, logged an event for something that shouldn't be logged, or logged too many unique event names. Blocked event data is not sent to Firebase Analytics.
    • Add Event: Use this option when you want to measure one event at the same time as another event.
      • Edit parameter names in the Override Event Name field.
      • Use Parameters to Add/Edit to add key names and values. Click the Add Row button and enter the appropriate key names and values.
      • Use Parameters to Drop to drop key names when the tag is fired.
    • Modify Event: Use this option to keep parameter names consistent between different versions of your apps. For instance, your Android implementation might have an event called save_image, and your iOS implementation uses save_new_image for the same function.
      • Edit parameter names in the Override Event Name field.
      • Use Parameters to Add/Edit to add key names and values. Click the Add Row button and enter the appropriate key names and values.
      • Use Parameters to Drop to drop key names when the tag is fired.
    • Click Triggering and specify an appropriate event trigger that will fire this tag.

  5. Save and publish your tag configuration.

Enable Universal Analytics in Firebase projects with Tag Manager

With Firebase, you can activate a Tag Manager container for your app and then easily use Tag Manager to configure and deploy a Universal Analytics tag or any supported 3rd party tags.

To set up a Universal Analytics tag via Tag Manager:

  1. Get your app set up with Firebase:
    1. Install the Firebase SDK (Android | iOS).
    2. In the Firebase console, add your app to your Firebase project.
    3. Add Firebase Analytics to your app (Android | iOS).
  2. Create a Tag Manager account and configure a Tag Manager container.
  3. Add Tag Manager to your project (Android | iOS).
  4. Create your Google Analytics tag in Tag Manager.
Due to the deprecation of the InstallBroadcast API, Universal Analytics no longer supports the attribution of new users for apps. Please consider switching to the next generation of Google Analytics 4.

Once your app has been compiled with Firebase and Tag Manager, you can add any additional tags from the Tag Manager interface with no need to rebuild your app.

IP anonymization is automatically enabled for the Firebase SDK and does not need to be set it in the Google Analytics settings variable.

Automatically collected events available in Tag Manager for Android and iOS

This table lists Google Analytics for Firebase's automatically collected events for Android and iOS that are accessible from Tag Manager:

Event Android iOS
app_exception  
app_update  
firebase_campaign
first_open  
in_app_purchase  
notification_dismiss  
notification_foreground
notification_open
notification_receive  
os_update
session_start
user_engagement

Modify and block events

Tag Manager gives you the ability to modify, add, or block custom events (even after the app has shipped) with the Google Analytics (Firebase) tag. By default, events logged in your app with the Firebase SDK will be sent to Google Analytics, even if Tag Manager is in use. This can be useful in cases where event names change between app builds and you want to collect consistent data from users that still have older versions of your app.

IMPORTANT: Use the Google Analytics (Firebase) tag only if you wish to modify, add, or block custom events that are logged by Firebase. Automatically collected events cannot be modified.

Related resources

Was this helpful?

How can we improve it?
Search
Clear search
Close search
Main menu
15658634499310459593
true
Search Help Center
true
true
true
true
true
102259
false
false