recently I published my app in Google Playstore and the thing is the google sign in is not working and returns Exception code: 10. The sign-in flow works fine in the debug mode while running the app on an emulator/physical device where I directly install that from android studio. But when I released the app in the Play Store now the sign-in is not working and it returned the error code: 10.
Asked
Active
Viewed 623 times
2
Alex Mamo
- 130,605
- 17
- 163
- 193
Mohammad Khalid Ibrahimi
- 379
- 2
- 13
-
1[Does this answer your question ?](https://stackoverflow.com/questions/49450140/google-signin-api-exception-10#:~:text=It%20returns%20Exception%20code%2010,will%20be%20treated%20as%20fatal.) Mostly the issue appears when you don't have production keystore file SHA1 added in your firebase. – Malik Saifullah Oct 03 '22 at 18:07
-
non of those solution helped me out. still getting the :10 error I also tried to add the SH1 of the google play console in App Signing Report, and added that into firebase but still with those 2 SH1 its not working – Mohammad Khalid Ibrahimi Oct 03 '22 at 18:25
-
its working fine while installing the app from android studio directly to device, google sign in flow is working but when installing the same from google play store it does not work the Google sign in and getting me the :10 error. – Mohammad Khalid Ibrahimi Oct 03 '22 at 18:27
-
When you say `its working fine while installing the app from android studio directly to device, google sign in flow is working but when installing the same from google play store it does not work` have you also tried installing the production flavor of the app or just the debug?. – Malik Saifullah Oct 03 '22 at 18:36
-
@MalikSaifullah Thanks but I don't understand the "production flavor". the main thing I want to say is while directly installing from the android studio or generating apk of the app from android studio the google sign in works but when I generated the signed apk/bundle and uploaded & released that in google play console and then for testing I install that from play store and the google sign then does not worked just returned the :10 error message. – Mohammad Khalid Ibrahimi Oct 03 '22 at 18:55
-
My bad - Production Flavor is the apk which you sign and upload it to play store. – Malik Saifullah Oct 03 '22 at 19:12
-
Let us [continue this discussion in chat](https://chat.stackoverflow.com/rooms/248523/discussion-between-malik-saifullah-and-mohammad-khalid-ibrahimi). – Malik Saifullah Oct 03 '22 at 19:14
-
Most likely this [answer](https://stackoverflow.com/questions/51360250/firebase-ui-authentication-with-google-fails-with-message-code10-message10/51360406) will help. – Alex Mamo Oct 04 '22 at 06:06
-
@AlexMamo Big help! Thank you so much! I will mark your answer as accepted. – Mohammad Khalid Ibrahimi Oct 06 '22 at 19:13
2 Answers
1
When it comes to having a working Google sign-in mechanism when the app is in production, then you should take into consideration following the next steps:
Generate the SHA-1 fingerprint certificate for debug mode. You can also read more information in the following resource:
Generate the SHA-1 fingerprint certificate for release mode.
Generate the signing key for Google Play.
You might also take a look at:
Alex Mamo
- 130,605
- 17
- 163
- 193
0
Besides the using correct SHA1 for the production build, also, make sure you set up the correct package name when configuring the Google API Console project https://developers.google.com/identity/sign-in/android/start-integrating#configure_a_project
sergpetrov
- 1,506
- 1
- 11
- 20
