How to Implement Firebase Remote Config on Android?

How to Implement Firebase Remote Config on Android?
3 min read

In this blog, we will find out about the Firebase Remote Config highlight in Android. By utilizing Firebase Remote Config, we can get a few updates to the Application like some text changes, and various changes in the Android Application, without distributing any update of the application on the Play Store.

How about we begin?

Adding Firebase Remote Config Dependency

To involve the Firebase Remote Config in Android Application, as a matter of some importance, we want to add the accompanying conditions in the application build gradle.

How to Implement Firebase Remote Config on Android?

Note: Remember to add google-services.json in your undertaking.

Download the "google-service.json" document from Firebase Control center.

In the undertaking, explore to the "application" envelope and glue the .json document.

Involving Remote Config in Android Project

Then, at that point, we can make a class RemoteConfigUtils like underneath:

How to Implement Firebase Remote Config on Android?

How to Implement Firebase Remote Config on Android?

Presently, we should comprehend what we have done in RemoteConfigUtils class:

  • DEFAULTS: HashMap to store key and the default esteem related with that key.
  • init(): The capability to introduce the remoteConfig. It utilizes the getFirebaseRemoteConfig

  • From that point onward, we have made the capabilities like getNextButtonText(), getNextButtonColor()to get to the text and the variety any place expected in our Application. We can make comparative more capabilities in view of our necessities.

Then, at that point, we can call the init capability from the Application class like underneath:

How to Implement Firebase Remote Config on Android?

Presently, we can utilize the capabilities to get the message and variety like beneath:

Yet, till now, we are utilizing the default text and color.

How to Implement Firebase Remote Config on Android?

Since we have previously distributed the Android Application on the play store, and we need to change the text and the foundation tone.

Refreshing Worth from Firebase Remote Config Console

We simply have to go to the firebase remote config console, put the key and the new worth related with that key like beneath in the firebase remote config console:

How to Implement Firebase Remote Config on Android?

That is all there is to it.

After this change, the following button text will be changed to Continue.

We have refreshed the text of the following button without refreshing the application on the play store.

Conclusion

Thus, in this blog, we found out about Firebase Remote Config, which is utilized to make little updates in your application without distributing the report on the play store. Remote Config is exceptionally helpful when we have a few minor updates in our application. Trust you partook in this blog. Thus, take a stab at executing the Remote Config to your application.

If you have any query regarding app development connect with our android app developers.

In case you have found a mistake in the text, please send a message to the author by selecting the mistake and pressing Ctrl-Enter.
Best Remote Team 86
Worried about the cost and time it would take to get your project off the ground? We BestRemoteTeam understand that finding the right team for your project is e...
Comments (0)

    No comments yet

You must be logged in to comment.

Sign In / Sign Up