How to unzip, edit and zip an android apk

user1662302 picture user1662302 · Apr 5, 2015 · Viewed 79.3k times · Source

I have an android apk and I deleted my source code and dont have the project again, I want to change the version code of the old apk. my question is how do I unzip and repack the apk so I can use the. am using a mac system. I saw so many things for windows but i couldnt find for mac.I need help please

Answer

Liu Tao picture Liu Tao · Aug 25, 2016

unzip apk files

The simplest method is executing unzip command:

unzip xxx.apk -d xxx

A directory xxx will be generated to store unzipped files. Actually, .apk files are same as .zip files. Execute command file XXX.apk to see that.

get readable text files from apk

If you want readable text files such as the manifest file, I would suggest you to use the apktool. We could install the apktool easily with Homebrew:

brew install apktool

then get the readable text files:

apktool d xxx.apk

after the previous command, a xxx directory contains readable text files and others would be there.

edit zip files

If you want to edit a zip file in place, the Keka might be a good option.