Lorixen.
EN

Google sign-in works in testing but fails in your Play Store app

Short answer: Google's sign-in for Android apps checks which certificate signed the app, using its SHA-1 fingerprint. Your debug builds are signed with your local debug key, and your Play Store installs are signed by Google with the app signing key, so they have different fingerprints. If only the debug fingerprint is registered with your Google Cloud or Firebase project, sign-in works on your machine and fails for real users. Copy the app signing key's SHA-1 from Play Console, add it to the same project, and test with a build installed from Google Play.

Why it works for you and not for customers

When an Android app asks Google to sign someone in, Google checks that the request comes from your genuine app. It does that with two things: the app's package name and the SHA-1 fingerprint of the certificate it was signed with. Google's client authentication guide says certain Google Play services, including Google Sign-in, require the SHA-1 of your signing certificate so an OAuth client can be created for your app.

An app can be signed with up to three different keys during its life:

  • Debug key. Created automatically on each developer's machine and used for builds you run from your development tools.
  • Upload key. Play Console Help describes it as the key you use to sign your app bundle before uploading it, so Google can verify it came from you.
  • App signing key. Held by Google Play, which uses it to sign the APKs delivered to users' devices.

If you use Play App Signing, which Google's guide notes is a requirement when publishing Android App Bundles, the app on customers' phones carries the app signing key's certificate, not yours. A fingerprint registered from your laptop won't match.

The symptom

Sign-in fails without a helpful message for users: the account picker appears and then nothing happens, or the app shows a generic error. In your logs or crash reports you may see a developer or configuration error from the Google sign-in library, commonly reported as DEVELOPER_ERROR or status code 10. The exact wording depends on which library and version you use.

The fix, step by step

  1. Find the app signing key's SHA-1. Google's guide says that if you use Play App Signing, you can get it in Play Console under Release, Setup, App integrity. Copy the SHA-1 of the app signing key certificate.
  2. Also copy the upload key's SHA-1 from the same page if you distribute builds signed with your upload key, for example to testers outside Google Play.
  3. Add the fingerprints to the Android OAuth client in your Google Cloud project, or to your Android app's settings in Firebase if you use Firebase Authentication. Make sure the package name matches exactly, including any suffix used by different build variants.
  4. Download an updated configuration file if you use Firebase and your app bundles its config file.
  5. Test properly. Install the app from an internal testing track in Google Play, not from your machine, so you're running the exact build Google signs.

If you don't use Play App Signing, Google's guide explains how to get the SHA-1 with Java's keytool or Gradle's signingReport. Register the fingerprint of the key you actually release with.

Keep every build working

Register a fingerprint for each way your app is signed:

  • the debug key on each developer's machine, or a shared debug keystore kept in the project
  • the upload key, for builds shared directly with testers
  • the app signing key, for everything from Google Play

Different build variants with different package names, such as com.example.app.staging, need their own OAuth client entries too.

Other causes worth ruling out

If the fingerprints are right and sign-in still fails:

  • Wrong project. The web client ID your app requests a token for must be in the same project as the Android OAuth client.
  • OAuth consent screen not ready. If the consent screen is in testing mode, only listed test users can sign in.
  • A changed package name after a rebrand, while the OAuth client still uses the old one.
  • Outdated sign-in library. Google has been moving Android apps to newer sign-in APIs; follow the current guidance for your library and keep it up to date.

When you change keys

If you ever request an upload key reset, update the registered upload key fingerprint. The app signing key usually stays the same for the life of the app, so customers' sign-in keeps working, but check after any change in App integrity.

Write it down for the next developer

Add a short note to your project's README listing every OAuth client, the package name each one uses and which key fingerprint belongs to which build. When a new developer joins or an agency hands the app back to you, this is exactly the knowledge that goes missing, and rebuilding it means another round of failed sign-ins.

A worked example

An illustrative Calgary gym's class booking app added "Continue with Google". It worked perfectly in every test on the developer's phone. On launch day, members reported that tapping the button did nothing. The crash reports showed a developer error from the sign-in library. The developer had registered only the debug key's SHA-1 in Firebase. They copied the app signing key's SHA-1 from Play Console's App integrity page, added it alongside the upload key's fingerprint, and tested through the internal testing track. Sign-in worked for everyone, with no new app release needed.

FAQ

Do I need to publish a new version after adding the fingerprint?

Usually not, if the configuration is checked on Google's side. If your app bundles a config file that changed, publish an update.

Is it safe to share the SHA-1?

Yes. It's a fingerprint of a public certificate, not a secret. Keep the keystore and its passwords private.

Does this affect iOS?

No. iOS apps use their own client ID and bundle identifier.

Why does it work on the internal test track but not production?

They're signed with the same app signing key, so check package names and that you're testing the same app entry.

If your app's Google sign-in fails after release, tell us how the app is built and published and we'll help you check the signing setup.

Sources

WhatsAppBook a call