Fix "INSTALL_FAILED_UPDATE_INCOMPATIBLE: signatures do not match" on Android
adb: failed to install app-release.apk: Failure [INSTALL_FAILED_UPDATE_INCOMPATIBLE: Package com.example.app signatures do not match previously installed version; ignoring!]
- Failure [INSTALL_FAILED_UPDATE_INCOMPATIBLE: Existing package com.example.app signatures do not match newer version; ignoring!]
- Execution failed for task ':app:installDebug'. > com.android.builder.testing.api.DeviceException: com.android.ddmlib.InstallException: INSTALL_FAILED_UPDATE_INCOMPATIBLE: Package com.example.app signatures do not match the previously installed version; ignoring!
- The device already has an application with the same package but a different signature. In order to proceed, you will have to uninstall the existing application.
- App not installed as package conflicts with an existing package.
A version of the app with the same package name but signed with a different key is already installed on the device, and Android refuses the update. Uninstall it with adb uninstall com.example.app (its data will be wiped), then reinstall; to keep it from coming back, share the same debug keystore or add an applicationIdSuffix to the debug build.
What this error means
On Android, an update is only accepted if the new APK is signed with the same certificate as the installed version: this is what stops a malicious app from replacing yours and taking over its data. The package manager compares the signatures and, if they differ, rejects the install with INSTALL_FAILED_UPDATE_INCOMPATIBLE. During development, this almost always happens because you switch between a debug build (signed with the debug keystore generated on each machine) and a release build or a Play Store version (signed with another key). Neither adb install -r nor -d bypasses this check.
Common causes
- Debug over release (or the reverse): the release or Play Store version is signed with your production key or the Play App Signing key, the debug version with
debug.keystore. - Different debug keystore: each machine generates its own
~/.android/debug.keystore; a debug APK built by a teammate, by CI or after reinstalling Android Studio has a different signature. - App still installed for another user: uninstalled from the main profile but still present in a work profile, a "second space" or another user on the device.
- Cloud and local builds mixed up: an APK produced by EAS Build, Codemagic or another CI is signed with credentials managed by that service, not with your local key.
Step-by-step fix
-
Confirm the app is already installed
Check the package name on the device. With several devices or emulators connected, add
-s <serial>(list them withadb devices). The commands are the same on Windows, macOS and Linux.adb devices adb shell pm list packages | grep com.example.app # Windows (PowerShell) adb shell pm list packages | Select-String com.example.app -
Compare the signatures (optional)
To understand where each version comes from, print your project certificates with the
signingReportGradle task, and the certificate of an APK withapksigner(in the SDKbuild-tools).cd android ./gradlew signingReport apksigner verify --print-certs app/build/outputs/apk/release/app-release.apk -
Uninstall the existing version
adb uninstallremoves the app for every user on the device, which also handles the work-profile case. Careful: the app local data is wiped; export it first if it matters.adb uninstall com.example.app -
Reinstall
Install the APK again, or run the build again from your usual tool.
adb install app/build/outputs/apk/debug/app-debug.apk # or ./gradlew installDebug npx react-native run-android flutter run -
Share one debug keystore across the team
So that every debug build has the same signature, commit a debug keystore in the project (the React Native template already does it with
android/app/debug.keystore) and declare it inapp/build.gradle.kts. This is acceptable only for the debug key, whose passwords are public; never commit your release keystore.android { signingConfigs { getByName("debug") { storeFile = file("debug.keystore") storePassword = "android" keyAlias = "androiddebugkey" keyPassword = "android" } } } -
Install debug and release side by side
A suffix gives the debug build another package name (
com.example.app.debug): both versions live together with no signature conflict. Remember to register that package in Firebase or any service that checks the identifier.android { buildTypes { getByName("debug") { applicationIdSuffix = ".debug" } } }
Did this fix work for you?
Confirm it in one click: it will rise for the next developers stuck on the same error.
Keep it from coming back
- Add
applicationIdSuffix = ".debug"from the start of the project so you never mix a debug build and the Play Store version on your phone. - Use the same debug keystore on every machine and in CI, and keep the release keystore out of the repository, backed up in a secrets vault.
- To test the Play-signed version, use an internal testing track instead of installing a local release APK over it.
Frequently asked questions
Can I update without uninstalling?
No, not with another key: Android requires the same certificate. The only exception is APK Signature Scheme v3 key rotation, which must be signed by the old key; it is not a fix for a debug / release mix-up.
Does adb uninstall -k keep the data?
It keeps the data, but the app can then only be reinstalled with the same signature, which does not solve this problem. Back up the data through the app itself before a full uninstall instead.
Why does the error come back after I uninstalled the app from the phone?
It is probably still installed for another user or profile (work profile, second space, Samsung Secure Folder). adb uninstall com.example.app removes it for every user.
Useful tools for this error
More Mobile (Android, iOS) errors
- Fix "SDK location not found" (ANDROID_HOME / sdk.dir) on Android
- Fix "CocoaPods could not find compatible versions for pod" on iOS
- Fix "Unable to load script" (index.android.bundle) in React Native
- Fix "Signing for "App" requires a development team" in Xcode
- Fix "Duplicate class ... found in modules" in an Android Gradle build
- Fix "cmdline-tools component is missing" and "Android license status unknown" (flutter doctor)
- Fix "Invariant Violation: "main" has not been registered" (React Native / Expo)