Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Firebase Phone Auth not working in release build

The OTP verification works properly for debug build. I have also added SHA key in firebase console for release version. But Phone Auth doesn't work when I generate signed apk and upload it to play store. Should I retain both debug SHA keys and release keys after I upload the app to production on play store? Is Google App Signing compulsory for using a firebase app on production?

like image 907
Ajay Srinivas Avatar asked Oct 28 '18 17:10

Ajay Srinivas


2 Answers

You need to add SHA-1 certificates. And if they are already added and you still face this problem (as in my case). Add SHA-256 as well and it works!!!

like image 102
salvi shahzad Avatar answered Oct 30 '22 07:10

salvi shahzad


If this is the issue occurring on the app uploaded to play store, then below can be a feasible solution.

Steps

  1. Go to play console and select your app.
  2. Under release management, go to app signing.
  3. Find SHA-1 certificate and copy it.
  4. Go to firebase console and select your app.
  5. Go to project settings and add this SHA-1 certificate.

You are ready to rock again.

like image 22
Prashant Paliwal Avatar answered Oct 30 '22 07:10

Prashant Paliwal