Something More for Research

Explorer of Research #HEMBAD

How to convert apk file to source code

Posted by Hemprasad Y. Badgujar on August 9, 2014

Step 1:
Make a new folder and put .apk file in it (which you want to decode). Now rename the extension of this .apk file to .zip (eg. rename from filename.apk to and save it. Now you get classes.dex files, etc. At this stage you are able to see drawable but not java & xml files, so continue.
** UPDATE: Android Complete tutorial now available here.
Step 2:
Now extract this zip apk file in the same folder. Now download dex2jar from this link dex2jar and extract it to the same folder. Now open command prompt and change directory to that folder. Then write dex2jar classes.dex and press enter. Now you get classes.dex.dex2jar file in the same folder. Then download java decompiler from this link and now double click on jd-gui and click on open file. Then open classes.dex.dex2jar file from that folder. Now you get class files and save all these class files (click on file then click “save all sources” in jd-gui) by src name. At this stage you get java source but the xml files are still unreadable, so continue to Step 3.

Step 3:
Now open another new folder and put these files

  1. Put .apk file which you want to decode
  2. Download apktool v1.x AND apktool install window using Google( (Very important first download apktool-install-windows-r05-ibot and extract the file . Second download apktool1.5.2, extract jar in that and put it in same folder ) and put in the same folder
  3. Download framework-res.apk file using Google and put in the same folder (Not all apk file need framework-res.apk file)
  4. Open a command window
  5. Navigate to the root directory of APKtool and type the following command: apktool if framework-res.apk
  6. apktool and "fname".apk (“fname” denotes filename which you want to decode)

Now you get a file folder in that folder and now you can easily read xml files also.

Step 4:
It’s not any step just copy contents of both folder to the single one and now enjoy with source code.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

Extracts from a Personal Diary

dedicated to the life of a silent girl who eventually learnt to open up

Num3ri v 2.0

I miei numeri - seconda versione


Just another site

Algunos Intereses de Abraham Zamudio Chauca

Matematica, Linux , Programacion Serial , Programacion Paralela (CPU - GPU) , Cluster de Computadores , Software Cientifico




A great site

Travel tips

Travel tips

Experience the real life.....!!!

Shurwaat achi honi chahiye ...

Ronzii's Blog

Just your average geek's blog

Karan Jitendra Thakkar

Everything I think. Everything I do. Right here.


News About Tech, Money and Innovation

Chetan Solanki

Helpful to u, if u need it.....


Explorer of Research #HEMBAD


Explorer of Research #HEMBAD


A great site


This is My Space so Dont Mess With IT !!

%d bloggers like this: