Rajesh Lawrance
Rajesh Lawrance

Reputation: 161

How to obtain the private key for getting a signed apk file in android?

I want to know the information of publishing an android apk in google play store.i read the developer website.But i struggled to get the private key for apk file.how to get the signed apk file with release mode.so i need some step by step process.

Upvotes: 4

Views: 15024

Answers (4)

Siddharth Lele
Siddharth Lele

Reputation: 27748

Here a few steps to help you create a release private signing key:

  1. Select File -> Export
  2. In the pop-up, expand Android and select Export Android Application
  3. In the next pop-up, select the Browse button and select the Project you need to publish the APK of.
  4. Click the Next button. The next set of options, is for selecting an existing Keystore or creating a new one. Choose Create new keystore, set a location where you want to save the keystore file, choose your own password and confirm the same.
  5. Next page is the Key Creation set of options. In this, create an alias for the keystore. Again, choose a password and confirm the same. Set a validity in number of years for your keystore. It has to be a minimum 25 years. Enter the rest of the details on this page.
  6. On the final page of this wizard, choose the location where you want the APK to be saved on your computer.

That's all there is to it.

NOTE: The release signing key is to be created by the developer and not by Google for the dev. It is a self signed certificate. Keep this key safe and secure, and possibly in multiple locations. If you are to loose access to the signing key file created in Step 4 above, you will not be able to publish updates to your application. There are no known ways of recovering a lost key. The same applies to the passwords you select in the process above. Do not loose either the key file or it's passwords.

Read more about signing your applications here: http://developer.android.com/tools/publishing/app-signing.html

Upvotes: 7

GrIsHu
GrIsHu

Reputation: 23638

Check this out : Compile the application in the release mode

Android Tools > Export Signed Application Package


Support for a true debug build. Developers no longer need to add the android:debuggable attribute to the tag in the manifest — the build tools add the attribute automatically. In Eclipse/ADT, all incremental builds are assumed to be debug builds, so the tools insert android:debuggable="true". When exporting a signed release build, the tools do not add the attribute. In Ant, a ant debug command automatically inserts the android:debuggable="true" attribute, while ant release does not. If android:debuggable="true" is manually set, then ant release will actually do a debug build, rather than a release build.

Upvotes: 0

MuraliGanesan
MuraliGanesan

Reputation: 3261

There's a guide to signing Android applications on the developer website:

http://developer.android.com/guide/publishing/app-signing.html

Upvotes: 0

Sourabh Saldi
Sourabh Saldi

Reputation: 3587

If you are using eclipse right click on your project >tools>export signed apk

then follow the steps. You will be asked to either use existing or generate a new key there select option to generate new key and a new key will be generated

Upvotes: 0

Related Questions