Login

Help

Documentation

Google Analytics

Twixl Support Team Updated: - Created :

    To allow your app to send data to Google Analytics, follow these steps:

    In Google Firebase

    1. Get started by creating a project
      - Go to
      https://console.firebase.google.com/ > Sign in with a Google Account
      - Create a Project > Enter a Project Name (e.g. the name of your app)
      - Choose a Project ID or accept the proposed one.
      You can also select an existing Project to setup Firebase for.
    2. For Android apps: Generate your Google Services JSON file
      - In Project Overview > Project Settings > General > Add app > Android icon
      - Fill in the Android package name* > optionally specify an App nickname > Click Register
      - Download the google-services.json file > Save the file to your device

      *  An Android package name is a reverse DNS name like com.mycompany.appname.
    3. For iOS apps: Generate your Google Services Info file
      - In Project Overview > Project Settings > General > Add app > iOS icon
      - Fill in the Apple Bundle ID** > optionally specify an app nickname > Click Register
      - Download the GoogleService-Info.plist file > Save the file to your device

      ** An Apple Bundle ID corresponds to the Bundle ID in the build settings which is a reverse DNS name like com.mycompany.appname
    4. For the Browser Client: Get the config
      - In Project Overview > Project Settings > General > Add app > code icon
      - Fill in a name for the project > Click Register
      - Go to Project Overview > Project Settings > General > Select the webapp project > Config > Copy icon
    5. Integrate Google Analytics in Firebase Project
      - Go to Project Overview > Gear icon
      > Project Settings > Select 'Integrations' > Google Analytics > Select 'Enable'

    On the Twixl platform

    Once you have finished the previous steps, upload the files to the Twixl platform.

    1. For analytics about the app usage:
      - Go to Build > Build Settings > Select your Build Setting
      - In 'Push Notifications and Google Analytics' > Upload the saved google-services.json and/or GoogleService-Info.plist file(s)
    1. For analytics about the browser client usage:
      - Go to Advanced > Browser Client > Promotion & Analytics > Paste the Config from Step 5 above

    After you have setup Google Analytics, you'll need to update your app by creating a new build with the latest Twixl version to start gathering data. Only then the project in Google Analytics will start to collect analytics data.

    Click here for more information about Google Analytics.