Search code examples
androidapkapktool

How to extract source code from installed app?


I was developing an Android app for more than a month, but my computer crashed and I lost all the code from it. I have a compiled app installed on a test phone and tablet. Is there any way to extract source code from it?
I followed some guide for game modders (they are probably doing something similar), and I have extracted .apk with an app called Total Commander. Now the guide states that I should extract it with the apktool. But all files are still in binary (when I opened them I got random chars). Now, is there any tool (for Linux) that can decompile .apk back to source code, or maybe some feature of apktool I miss?

Note: I also tried this answer from 10 but also without success.
EDIT: javadecompileonline also did not decompile binaries correctly, so this should be .json file:

<m*/��%kي%jTƴ���69/�t��
č   �Cx���Q�đš?������i�
ć���/��i�JRᙱg�.�s

Solution

  • First you go to Android studio's welcome page there is a option to extract source code from APKs.

    Another way is to install this apk extractor application from play store then you can extract source code from APKs Link : https://play.google.com/store/apps/details?id=com.ext.ui