Fork me on GitHub

Shrink, Obfuscate and Optmize your APK with Proguard


When packaging an apk, all classes of all libraries used by the program will be included. Potentially this makes the apk very huge, even exceeding the capacity of dex. ProGuard can strip unused classes and methods, make it as small as possible. In addition it can be used to obfuscate the classes in your apk.

The android maven plugin has built in support for ProGuard with the link./proguard-mojo.thml[proguard goal]. It supports using the proguard.cfg file and you can activate it with


The ProGuard version used is determined by the plugin itself and set to the latest available version. If desired, a plugin-specific dependency declaration can be used to override the preconfigured version.


Complete setup with more options can be found in the Morseflash as well as the Scala example projects.