Tips for building a quality app with Firebase
By: Maria Neumayer
Tags: Firebase, Android App Development, Google Play, Android Developers, Featured

Tips for building a quality app with Firebase

This article is based on Google’s Apps, Games, & Insights podcast episode featuring Maria Neumayer, Staff Software Engineer at Deliveroo alongside Shobhit Chugh, Product Manager at Firebase.

Over the last few years, users’ expectations of apps have increased. First impressions count. An app that crashes, hangs, or drains battery life, probably has a competitor that provides the same features but with a much, much better experience. To meet these expectations and keep ahead of the competition, developers are investing more into their apps’ usability and technical capabilities.

In this article, I’ll take you through some of the things Deliveroo does to ensure our app is always at its best.

What is app quality?

Before I get to the tips, let’s take a look at what makes up app quality. App quality is a holistic view of the customer experience: from interacting with the app’s functionality — can people perform the task they came to do quickly and easily? — through to the presence of technical issues — does the app crash or freezes, are there performance issues, is it slow to load? All these things make up app quality.

Source: Deliveroo

Tip 1: Test and test again

Testing is one of the critical steps we take in ensuring our app is stable. Start with the basics, test your code with unit, integration, and UI tests. Use your team and others in your organization to test internally before you roll out. Consider involving your community in closed or open tests.

There are the tools to support code testing in Android Studio and the Google Play Console, such as internal, closed, and open testing. Firebase also includes tools to enable testing, such as Firebase Test Lab.

Tip 2: Use feature flags

Firebase remote config can enable you to integrate feature flags into our workflow, which helps with app quality:

When you roll out a new release and find out a feature isn’t functioning as intended, you use the feature flag to disable that functionality, avoiding the need to roll back the entire release. When you use feature flags to roll out multiple versions of an update by enabling or disabling features based on devices. This helps to perform rollout tests to determine which set of features works best on different devices and decide which features are distributed to all users.

Tip 3: Setup release readiness metrics

It can often be challenging to figure out when a build is ready for release. Using various Firebase tools, such as App Distribution, Crashlytics, and Performance Monitoring, we can easily share our app’s pre-release versions to the team for internal testing. We also get in-depth crash and performance reports that give us the confidence to launch the app. Deliveroo went from 99.35% crash-free sessions to >99.7% by using Crashlytics to identify, fix bugs, and monitor releases.

Tip 4: Automate your release

Don’t rely on manually executed release steps; get everything into scripts as soon as possible. At Deliveroo, automation includes lint checks as part of continuous integration (CI) to ensure the translated strings are in the right format. We also run a release script to create a tag on GitHub, which triggers the release build on CI and uploads the build to the play store. Switching to automated scripts led to a significant decrease in time to market for the Deliveroo team.

Tip 5: Set your rollout thresholds in advance

Once Deliveroo starts the rollout, we don’t want to be figuring out on the fly whether a particular metric means we should halt or abandon the release. We set up a baseline for the maximum acceptable crash rate. Should the crash rate exceed this maximum, we focus the development team on finding and fixing the issue. We use the Firebase Crashlytics velocity alert for quicker alerts for releases that are just rolling out. This feature means we can get alerts from the beginning of rollout, rather than a few hours later when enough users are on the release.

Therefore, it’s important to set your benchmark thresholds for critical metrics. You can then be proactive in fixing any app stability issues whenever your critical metrics near the threshold.

Tip 6: Use stage rollouts

When rolling out an update, use stage rollouts in the Play Console. With a staged rollout, your update is delivered to a subset of your users. If the feature performs well with your subset of users, you can increase the number of users receiving the update. Alternatively, if the feature doesn’t behave as intended, you can halt the rollout to fix the problem or abandon the rollout completely. This approach helps keep the number of users affected by unexpected issues to a minimum.

Tip 7: Set up alert notifications

Make use of alert notifications to bring issues to your attention as soon as they occur. For example, Firebase Crashlytics velocity alerts can notify your team when an issue is causing an urgent problem in your app. You can also use notification preferences in the Play Console to set up an email alert for when your app gets a one-star rating.

Deliveroo exports data to BigQuery and imports it into an internal tool to set up the alerts needed to find out how well a release is going. For example, during the rollout, because we can group errors, we can dig into the data in BigQuery to see what is happening and how many users are affected.

Tip 8: Use custom logs and keys in Crashlytics

One of the common rollout challenges is the “it works on my machine” phenomenon. Your app can be installed on hundreds of different device types, with many different configurations on each device type. As a result, developers can spend a lot of time unsuccessfully trying to reproduce crashes because they can’t figure out the configuration that caused the crash. Crashlytics helps capture the configuration of the device, the user’s actions, and the state of the app. When an issue arises, using custom logs and keys in Crashlytics makes it easier to reproduce a crash and know which events led to the crash.

Tip 9: Review and monitor user feedback.

Monitor user ratings and reviews as they are a great way of keeping on top of things. Deliveroo monitors how orders are delivered and if their customers are happy. While this is outside the app development process, it provides feedback to the development team. Another approach is to use an analytical tool to check how many users are using key features. If the use of a feature suddenly drops, there could be an issue.

Check out the Android Developer guide on how to Browse and reply to app reviews to positively engage with users for more advice on engaging with users through reviews.

Conclusion

Users’ expectations have increased, and many companies are investing more into their app’s usability and technical capabilities to help keep users engaged. Firebase and Google Play app quality tools have helped make our app best in class and ensure people get the most out of our service.

Find out more

Learn more about integrating Firebase and Google Play app quality tools into your release workflow from the How to increase app quality with Firebase and Google Play blog post.

Hear Shobhit Chugh and Maria Neumayer talk to Google about building quality apps on episode 13 of the Apps, Games, & Insights podcast. Look out for upcoming articles from other episodes in our podcast series.

What do you think?

Do you have thoughts on building quality apps? Let us know in the comments below or tweet using #AskPlayDev and we’ll reply from @GooglePlayDev, where we regularly share news and tips on how to be successful on Google Play.