Maaz Zindani

Loading the index…

↑↓ move↵ openesc close4072 pages
Flutter and app store releases

Google Play rejects the upload because the bundle is signed with the wrong key

ErrorYour Android App Bundle is signed with the wrong key. Ensure that your app bundle is signed with the correct signing key and try again.

Short answer

With Play App Signing, Play Console expects every upload to be signed with your upload key, not the key Google uses to sign installs. The error means the bundle was signed with a different keystore or alias, or the release build used the wrong signing config. Check which key signed the build, re-sign with the registered upload key, or request an upload key reset if it is lost.

  • Applies to Android Gradle Plugin 8.x, Android Studio, Play App Signing, Flutter 3.35
  • Updated
  • By Maaz Zindani, Senior Software Engineer

Fix it fast

  1. 1Find out which cause you have

    List the signing config each variant really uses, so you can see which keystore and alias signed the release bundle. Run it from the folder that holds gradlew (android/ in a Flutter project).

    ./gradlew signingReport
  2. 2Match what you see, then jump to its fix

    1. 1The report shows a keystore or alias you did not register in Play Console, or a different alias than beforeThe bundle was signed with a key that is not your registered upload keyFix
    2. 2signingReport shows the release variant with the debug keystore under .androidThe release build is still using the debug keyFix
    3. 3You no longer have the keystore that signed the first release, so no key you hold matchesThe upload key is lost or was never keptFix

What does the error look like?

  • Your Android App Bundle is signed with the wrong key. Ensure that your app bundle is signed with the correct signing key and try again.

Cause 1 of 3

The bundle was signed with a key that is not your registered upload key

1Check

Play App Signing uses two keys. Google keeps the app signing key. You keep the upload key and sign every bundle with it. Compare the keystore path and alias in the report with the upload key you used for the first release.

./gradlew signingReport

2Fix

Point the release signing config at the keystore and alias of the upload key and rebuild. Keep passwords in a properties file, not in the build file.

android {
    signingConfigs {
        create("release") {
            keyAlias = keystoreProperties["keyAlias"] as String
            keyPassword = keystoreProperties["keyPassword"] as String
            storeFile = file(keystoreProperties["storeFile"] as String)
            storePassword = keystoreProperties["storePassword"] as String
        }
    }
    buildTypes {
        release {
            signingConfig = signingConfigs.getByName("release")
        }
    }
}

3Verify

Run the report again and confirm the release variant shows the upload keystore, then upload the new bundle.

./gradlew signingReport

Confirmed by developer.android.com

Did this fix it?

Cause 2 of 3

The release build is still using the debug key

1Check

Flutter's project template points the release build type at the debug signing config until you add your own. Google Play does not accept apps signed with a debug certificate.

./gradlew signingReport

2Fix

Create a release signing config with your upload key and assign it to the release build type, as in the first cause. In a Flutter project, run flutter clean after changing the Gradle file so cached output is not reused.

flutter clean
flutter build appbundle

3Verify

The bundle is written to build/app/outputs/bundle/release/app.aab. Upload that file.

ls -l build/app/outputs/bundle/release/app.aab

Confirmed by docs.flutter.dev

Did this fix it?

Cause 3 of 3

The upload key is lost or was never kept

1Check

Google cannot give the app signing key back, but the upload key can be replaced because it is separate. Confirm you really cannot find the original keystore and its alias.

./gradlew signingReport

2Fix

Create a new upload key, export its certificate in PEM form, then in Play Console open the Play app signing page and use Request upload key reset with that file.

keytool -export -rfc -keystore upload-keystore.jks -alias upload -file upload_certificate.pem

3Verify

After Google approves the reset, sign the bundle with the new upload key and upload it.

./gradlew signingReport

Confirmed by support.google.com

Did this fix it?

How do I stop it coming back?

  • Store the upload keystore, its alias and both passwords in a password manager and in a private backup.
  • Keep keystore details in a key.properties file that is not committed to source control.
  • Run signingReport before the first upload of every new project, and note the alias used.
  • Use a separate upload key from the app signing key so a lost key can be reset.

Sources

How was this page made?

I drafted this page with AI assistance from the official documents listed under Sources. Every cause above names the document that confirms it. I have not reproduced this fix on a machine of my own yet, so read it as documented guidance, not a test report. Found a mistake? Tell me.

Which stack is behind this page?

Projects of mine built on the same technologies:

Related fixes

Mobile apps

Google Play says your upload was signed in debug mode

You uploaded an APK that was signed in debug mode. You need to sign your APK in release mode.

Google Play does not accept anything signed with the debug certificate that Android tools create for development.

3 causes, each with a fix

Mobile apps

Google Play says the app does not support 16 KB memory pages

check_elf_alignment.sh reports UNALIGNED for a library under lib/arm64-v8a

Google Play requires apps that target Android 15 or higher and ship native .so libraries to run on devices with 16 KB memory pages; from 1 February 2027 it will block updates that do not.

5 causes, each with a fix

Next step

Want this handled for good?

I look after servers, apps and releases end to end. Tell me what keeps breaking.