Join the social network of Tech Nerds, increase skill rank, get work, manage projects...
 
  • How to reduce APK size android

    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 278
    Comment on it

    This blog is about reducing apk size with little tricks.

     

    1. Use Proguard. :- Proguard main feature are Obfuscation and shrinking. Obfuscation is prevent from reverse engineering. Shrinking eliminates unused code and shrink code and resources.


    Proguard also rename classes, fields, and methods with semantically obscure names. The result is a smaller sized .apk file that is more difficult to reverse engineer.


    2. Drawables :- Drawables helps to reduce the apk size.

    Use 8 bit png images instead of true color png images.

    Use 9 patch image for backgrounds for all devices instead of adding images in different drawable folders.

    Use Shape Drawable : - Shape Drawables are XML files which allow to define a geometric object with colors, borders and gradients.
    Shape drawable automatically adjust to correct size according to screen size.


    3. AndroidUnusedResources.jar :- Use AndroidUnusedResources.jar file to reduce apk size. This jar will search for unused resources from your app. You can remove the unused resources and reduce the apk size.  You can find jar fril from :- http://code.google.com/p/android-unused-resources/

     

    Happy coding.

 0 Comment(s)

Sign In
                           OR                           
                           OR                           
Register

Sign up using

                           OR                           
Forgot Password
Fill out the form below and instructions to reset your password will be emailed to you:
Reset Password
Fill out the form below and reset your password: