How To Create Android App Publishable APK File

When you finish your Android app coding and testing, if you want to publish it to the google play store, you should create a publishable app (.apk) file. This article will show you how to create a publishable app (.apk) file step by step.

1. Generate Publishable APK File Steps.

  1. Open Android Studio, click ” Build —> Generate Signed APK ” on the top toolbar menu.
  2. There will popup a dialog with the title Generate Signed APK. There are two sections in the dialog, Key store and Key.
  3. The Key store is a file that has the jks ( java key store ) file extension. This file will be used to save multiple different app keys.
  4. If you have multiple android apps, you can provide each app with one key.
  5. But it is best for you to use a single key to sign multiple Android apps because those apps signed with the same key can trust each other in communication. And it is easy to maintain.
  6. If you do not has an existing key store file, click the ” Create new…” button below the Key store path: textbox in the above Generate Signed APK dialog. There will pop up another dialog with the title New Key Store.
  7. You should select a Key store path with a key store file name (ie: C:\WorkSpace\dev2qa.com\androidExample.jks) and input a strengthened password for it. The key store file path must be an existing directory otherwise android studio will not create it for you.
    android-studio-new-key-store-detail-info-dialog
  8. In the New Key Store dialog window Key section, input an alias name for the new key in the Alias input textbox. The alias can not include white space and punctuation. Make sure the alias is unique in both character and character cases if you have multiple keys with multiple aliases.
  9. Input a strong password for the newly generated key in the Key section Password input textbox.
  10. The default Validity ( years ) value is 25, which is enough for your APK file. Because Google play store’s rule requires your key must be valid before October 22, 2033.
  11. Input your information in the Key section —> Certificate area.
  12. Click the OK button. It will return to the ” Generate Signed APK ” dialog. And all the key store and key information have been inputted in that dialog accordingly also.
    android-generate-signed-apk-dialog-filled-with-data
  13. Click the Next button, there will pop up another dialog. You can choose the APK Destination Folder and Build Type. The Build Type should be release in this example. Select at least one Signature Versions checkbox ( V1 (Jar Signature) or V2 (Full APK Signature)) at the bottom.
  14. Click the Finish button. Then you can get the publishable app APK release file (app-release.apk) in the android studio project folder. You can click here to see the detailed explanation for the Signature Version.

2. Build Android Debug APK File Steps.

  1. Open Android Studio, and click ” Build —> Build APK ” in the top toolbar.
  2. When the build process complete, there will popup a dialog at the right bottom of Android Studio. Click the link ( Show in Explorer )to open the folder where the APK file is created and saved.
  3. You can see a file named app-debug.apk in that folder ( \app\build\outputs\apk ).
0 0 votes
Article Rating
Subscribe
Notify of
guest

This site uses Akismet to reduce spam. Learn how your comment data is processed.

1 Comment
Newest
Oldest Most Voted
Inline Feedbacks
View all comments
Hamid Aurangzeb

Thanks for the complete guide but i am facing some issues in Generating Publishable APK for pkchitchat

1
0
Would love your thoughts, please comment.x
()
x