Predict your users with Firebase Predictions!
What is Firebase Predictions?
Firebase Predictions is a powerful product from the Firebase team, launched at Firebase Dev Summit 2017 to define dynamic user groups based on predicted behaviour that is backed by machine learning.
WHOA!? 😵 I don’t even know what Machine Learning is!
You don’t need to worry about it at all! Yes, you read it right 😎
Sounds interesting, but what does it DO?
Firebase Predictions uses the power of Google’s machine learning to create dynamic user groups based on users’ predicted behaviour. With Predictions, you can make informed product decisions without needing to build an in-house data science team or worrying about any machine learning stuff. It is also helpful to boost revenue & user retention through customisations.
How can I use Firebase Predictions in my project? 😋
Step 1: Connect Firebase with your project
Note: Firebase Predictions require Firebase Analytics to be enabled in order to log data & predict users’ behaviour
Step 2: Setup Firebase Analytics in your project
Step 3: See your data periodically in the Firebase Console 😁
Once the analytics data is available, you can use it to generate predictions! 🔥
Step 4: Configure Firebase Predictions in Firebase Console
- Go to “Predictions” tab from the navigation menu given in the left of Firebase Console.
- Read the explanation & click on “YES, I’M IN” button.
- You’ll see something like shown in the image above.
NOTE: Firebase Predictions is still in Beta mode.
Wait, what’s this!? “churn, not_churn, bla bla bla!” 🙄
By default, Firebase Predictions provides two types of predictions:
- churn: Predicts which users will disengage from your app over the next 7 days (that is, they will not open the app or app-related notification messages)
- spend: Predicts which users will spend money in your app over the next seven days.
not_churn & not_spend can be considered as the opposite of churn & spend respectively.
NOTE: Firebase Predictions uses 100 days of past data to generate predictions.
Can I get predictions of other user interactions? 😬
The answer is YES! 🎉
Step 5: Declare Events in your project
To enable & use your own predictions, you must first specify it in your code using mFirebaseAnalytics.logEvent()
method.
You can use FirebaseAnalytics.Event
& its Bundle
as key-value pair to specify inside logEvent()
as parameters.
OR
You can also declare your custom events!
Here’s the full list of Firebase Analytics Parameters that you can use to bundle & Firebase Analytics Event that you can log into Firebase Console.
Once you specify the events, Firebase will capture and log them in the Firebase Console. 😍
Step 6: Create custom predictions in Firebase Console
- To create a custom prediction, just click on “Create a prediction”.
Give prediction a name.
- Select event for which, you want to generate custom predictions.
NOTE: Firebase Predictions Accuracy data will be available after 10 days of predictions are collected.
What was the RISK-thing that you were talking about?! 😒
Its called “risk tolerance”.
But why? 😲
When predicting user behaviour, there is always a degree of uncertainty. You must decide, whether to include fewer users in a predicted group for higher overall accuracy, or to include more users for lower overall accuracy.
Step 7: Adjust risk tolerance
- High Risk Tolerance: Targets highest users count, lowest accuracy. This risk tolerance level is sometimes available when other risk tolerance levels are not.
- Medium Risk Tolerance: Targets a moderate number of users with a moderate accuracy level.
- Low Risk Tolerance: Targets the minimum number of users with the highest available accuracy level.
Predictions & tolerances are set, what’s next? 🤓
NOTE: Analytics, Events & Predictions data takes up to 24 hours in Firebase Console to be displayed. Firebase Console follows PST timezone. The data & statistics may take time to update accordingly.
Phew, how can I use all of this to increase user retention? 🙃
Here are some of the use-cases:
- Target users who are likely to make in-app purchase and increase them
- Target users with in-app promotions
- Use Firebase Remote Config to provide tailored experiences for separate user categories as a result of predicted behaviour
- Sending notifications to users for engaging them back in your app using Firebase Notifications
- Combining Firebase Predictions with Firebase A/B Testing to test new features with your specified user groups
And many more app-specific cases! Share your ideas in the comments below!
To learn more & get deeper insights, check the video & official Google Firebase Documentation here: Official Firebase Predictions Documentation
Don’t forget to give it a try & share your custom Prediction ideas in the comments below! 😈