Skip to main content

Setting up Firebase & GA4 with Reactiv

Introduction​

Integrating Google Analytics (GA4) with your Reactiv mobile app allows you to track and analyze user interactions effectively. Reactiv's Firebase integration empowers you to leverage Firebase Cloud Messaging. This guide will help you set up and configure these integrations for your Reactiv app.

Prerequisites​

Before starting, ensure you have the following:

  1. A Firebase account and project.
  2. Access to your Reactiv dashboard.
  3. Basic knowledge of Firebase and Google Analytics.

Step-by-Step Guide​

Step 1: Create a Firebase Project​

  1. Go to the Firebase Console: Visit Firebase Console.

  2. Create a Project: Click on "Add project" and follow the on-screen instructions to create a new project.

  3. Register Your App: In the Firebase project overview, click on "Add app" and select the platform (iOS/Android). Follow the instructions to register your app.

Step 2: Download Firebase Credentials​

  1. Download the iOS Configuration File:
  • Add your iOS app to firebase if your haven't already.
  • Open to Firebase Console and Select your App
  • Navigate to Project Settings > General
  • Scroll down to Your Apps and select the iOS app.
  • Download the GoogleService-Info.plist file

  1. Download the Android Configuration File:
  • Add your Android app to firebase if your haven't already.
  • Open to Firebase Console and Select your App
  • Navigate to Project Settings > General
  • Scroll down to Your Apps and select the Android app.
  • Download the google-services.json file

Step 3: Connect GA4/Firebase with Reactiv​

  1. Navigate to Shopify
  2. Open Reactiv - Mobile App Builder
  3. Navigate to Integrations
  4. Look for the Google Analytics (GA4) section and click on Connect
  5. You will receive the below Pop-Up where you will need to fill in the required fields; Firebase App ID (iOS), Measurement Protocol API Secret (iOS), Firebase App ID (Android), Measurement Protocol API Secret (Android)

How do I find my App ID?​

In the above downloaded file (for iOS or Android), open it to find the APP_ID (for iOS, this will be inside the GOOGLE_APP_ID field; for Android, it will be inside the app_id field).

Where do I find my Measurement Protocol API Secret in Firebase?​

Step 1: Go to Firebase Console​

  1. Visit the Firebase Console.
  2. Select the project that contains the app for which you want to use the Measurement Protocol API.

Step 2: Access Google Analytics Settings​

  1. In the left-hand sidebar, click on "Analytics".
  2. Select "Dashboard" (if not already in the dashboard).
  3. Click on the gear icon (⚙️) in the top-right corner of the Analytics dashboard to open the Analytics settings.

Step 3: Find Your Data Streams​

  1. In the Analytics settings, under Property Settings, click on "Data Streams".
  2. Choose the Data Stream (iOS, Android, or Web) for which you want to find the Measurement Protocol API Secret.

Step 4: Access Measurement Protocol API Secret​

  1. In the selected Data Stream, scroll down to the Measurement Protocol section.
  2. Click "Create" under the Measurement Protocol API Secrets section.
  3. Provide a name for the secret (e.g., "API Secret for My App").
  4. Click "Create".

Step 5: Copy the API Secret​

  1. Once created, you will see the API Secret listed.
  2. Copy this API Secret — you'll use it to authenticate requests when sending data using the Measurement Protocol.

Step 4: Documentation and Support​

  • For understanding GA4: Checkout Google's official documentation.
  • Contact Reactiv Support: If you encounter any issues, you can reach out to Reactiv Support for assistance.

Additional Notes​

  • Make sure you have the appropriate permissions in your Firebase and Google Analytics accounts to access the necessary IDs and secrets.

  • Ensure that your Reactiv app is updated to the latest version to support the GA4 integration.

Supported Events & Mapping​

All events listed below are forwarded to Google Analytics (GA4). Any personally identifiable information (PII) is fully redacted before events are processed or stored on Reactiv's servers.

Reactiv EventGA4 Event NameOfficial GA4?
ScreenViewedEventscreen_viewYes
CollectionViewedEventview_item_listYes
ProductViewedEventview_itemYes
SelectProductEventselect_itemYes
CartViewEventview_cartYes
CartItemAddedEventadd_to_cartYes
CartDiscountCodeAddedEventview_promotionYes
CheckoutStartedEventbegin_checkoutYes
CheckoutSuccessEventpurchaseYes
CheckoutFailedEventcheckout_failedCustom
SearchAppliedEventperform_searchCustom
SearchFilterAppliedEventperform_filterCustom
SearchSortAppliedEventperform_sortCustom
WishListItemAddedEventadd_to_wishlistYes
WishListItemRemovedEventremove_from_wishlistCustom
CartItemUpdatedEventupdate_cart_itemCustom
CartItemRemovedEventremove_from_cartYes
CartDiscountCodeSeenEventviewed_promotionCustom
CartDiscountCodeRemovedEventremove_promotionCustom
AccountSignUpSuccessEventsign_upYes
AccountSignUpFailedEventsign_up_failedCustom
AccountSignInSuccessEventloginYes
AccountSignInFailedEventlogin_failedCustom
AccountForgotPasswordEventforgot_passwordCustom
AccountRecoveredPasswordEventrecover_passwordCustom
AccountAddressAddedEventadd_addressCustom
AccountAddressUpdatedEventupdate_addressCustom
AccountAddressRemovedEventremove_addressCustom
ExternalLinkClickedEventclick_external_linkCustom
WebpageViewedEventview_webpageCustom
SubscribedToMarketingEventsubscribe_marketingCustom
QRCodeScannedEventscan_qr_codeCustom
PushPermissionAcceptedEventmobile_app_accept_pushCustom
PushPermissionDeclinedEventmobile_app_decline_pushCustom
LocationPermissionAcceptedEventmobile_app_accept_locationCustom
LocationPermissionDeclinedEventmobile_app_decline_locationCustom
AdsTrackingPermissionAcceptedEventmobile_app_accept_ads_trackingCustom
AdsTrackingPermissionDeclinedEventmobile_app_decline_ads_trackingCustom
ApplicationInstalledEventmobile_app_installCustom
NotificationOpenedEventnotification_openedCustom
ApplicationOpenedEventmobile_app_openCustom
ProductSharedEventshareYes
Was this page helpful?