Mehul Kanzariya Mehul Kanzariya - 1 year ago 279
Android Question

Unable to zipalign apk android android studio 2.2

I am publishing my app using android studio 2.2 preview 3 and generating signed apk. But when i am uploading apk to google play i am getting error

You uploaded an APK that is not zip aligned. You will need to run a zip align tool on your APK and upload it again.

Also i tried to used zipalign tool manually but i am getting error verification failed.

Here is my build.gradle file

android {
compileSdkVersion 23
buildToolsVersion "23.0.3"
defaultConfig {
applicationId "blackdogs.newaomsi"
minSdkVersion 16
targetSdkVersion 23
versionCode 1
versionName "1.0"
testInstrumentationRunner ""
buildTypes {
release {
zipAlignEnabled true
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), ''


Answer Source

Got it. Error was due to gradle version i was using. Downgraded gradle version to

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download