Rapid Subscribe Android App

Rapid Subscribe Android App
Rapid Subscriber

Recent Posts

[SOLVED] Google Sign-In working in Debug Mode but not working in Release mode | Error code 10 Developer Error

[SOLVED] Google Sign-In working in Debug Mode but not working in Release mode | Error code 10 Developer Error

In this post, We will show you how to solve Google SignIn Developer Error (Error Code-10).

We also solve an error of Google SignIn when SignIn working in debug mode but not working in Release mode.


Mainly, it is the error of the SHA-1 of our app.

Some reasons for Google SignIn Error Code 10 (Developer Error)
  • If you run your Google SignIn enabled app on another PC then use SHA-1 of that PC in Google API(Follow Step-1 to Step-6) 
  • If you release your app on Google Play then use release SHA-1 Key available on Google Play console. (Follow Step-7 to Step-9 and then Step-5 and Step-6)
How to find and use SHA-1, if you have to run your app on another PC.

Step-1. Open Android Studio and open your project.

Step-2. Then Open Views from Menubar then Tool Windows then click on Gradle.

Open Gradle from Android Studio
Open Gradle from Android Studio


Step-4. Then open your Project Name -> app -> Tasks -> android -> signing report

Find SHA-1 in Android Studio
Find SHA-1 in Android Studio



Then Your SHA-1 is written in your Run Section at the bottom of your Android Studio.

Then create an OAuth client in your Google API console and add your Sha-1 in there.


Step 5. open https://console.developers.google.com/ then select your Project and open Credentials here from the left menu.
Open credentials in Google Api Console
Open credentials in Google Api Console

Step-6. Under Create Credentials, create an OAuth Client and paste that SHA-1 Key here.
Create an OAuth client in Google Api Console
Create an OAuth client in Google Api Console

Now, with the above method, you can easily remove developer Error if you want to run Google SignIn enabled app in two different PCs.


If Google SignIn working in Debug mode, but not working in release mode then follow the below steps.

Step-7. GoTo https://play.google.com and open your app here

Step-8 Then go to Release Management and then click App Signing

Open App Signing in Google Play Console
Open App Signing in Google Play Console



Step-9 Copy SHA-1 under App Signing Certificate and follow Step-5 and Step-6 of this tutorial.

Now you have successfully learned about Google SignIn Error code-10 and why it is called Developer error.

 
Follow us for more posts like this, 
Subscribe to Harpreet studio on Youtube  
Like Harpreet Studio on Facebook  
Follow me on Instagram 

1 comment:

  1. I just came across this post, as I see the same error 10 in our app.

    When I add the SHA1 from our release keystore to the Google Cloud Console, the signin process is working when running a release build on device or emulator. When running a debug build on emulator, I see this error code 10.

    The other way around, when adding the SHA1 from the debug keystore, the sign in process stops working when running a release build.

    So my question is: how can I make sure that I am able to test the login stuff in a debug build on emulator (or device) AND people using the live app (when it is released on play store) can still use the sign in functionality at the same time? As I can only add one SHA1 to the Google Cloud Console.

    Btw, I am not using Firebase.

    I am thankful for any advice!

    ReplyDelete