Android ProGuard & R8 Rules Generator
Android Development# Generated ProGuard & R8 Configuration Rules
# Optimized for release builds & code shrinking
-keepattributes SourceFile,LineNumberTable
-keepattributes *Annotation*
# Custom Data Models
-keep class com.example.app.data.model.** { *; }
# Retrofit 2
-dontwarn retrofit2.**
-keep class retrofit2.** { *; }
-keepattributes Signature, InnerClasses, EnclosingMethod
-keepattributes RuntimeVisibleAnnotations, RuntimeVisibleParameterAnnotations
# Google Gson
-keepattributes Signature
-keepattributes *Annotation*
-dontwarn sun.misc.**
-keep class com.google.gson.** { *; }
-keepclassmembers class * { @com.google.gson.annotations.SerializedName <fields>; }
# Kotlin Coroutines
-dontwarn kotlinx.coroutines.**
-keepnames class kotlinx.coroutines.internal.MainDispatcherFactory {}
-keepnames class kotlinx.coroutines.CoroutineExceptionHandler {}Android ProGuard & R8 Rules Generator
Generate clean ProGuard and R8 obfuscation and shrinking rules with 1-click presets for Retrofit, Gson, Room, Kotlin Coroutines, and Glide.
How to Use Android ProGuard & R8 Rules Generator
Follow these simple steps to process your files securely in browser memory.
Select Active Libraries
Check libraries used: Retrofit, Gson, Room, Coroutines, Glide, Firebase.
Specify Model Packages
Enter app model package path (e.g. com.example.models.**) to preserve DTOs.
Copy proguard-rules.pro
Paste generated rules into app/proguard-rules.pro before building release.
Who Is Android ProGuard & R8 Rules Generator Built For?
Designed for professionals seeking fast, private, and unlimited client-side execution.
- Generating ProGuard/R8 rules for Retrofit, Room, Gson
- Preventing ClassNotFoundException crashes in release builds
- Keeping data models from obfuscation
Curated Library Presets
Battle-tested rules for Retrofit, OkHttp, Room, Gson.
Zero Release Crashes
Safeguard reflection without bloating APK size.
1-Click Copy Configuration
Drop ready rules into proguard-rules.pro.
Frequently Asked Questions about Android ProGuard & R8 Rules Generator
Related Android Development Tools
Android App Icon Resizer & Mipmap Generator
Generate Android app icons in all standard densities (mdpi, hdpi, xhdpi, xxhdpi, xxxhdpi) and Google Play Store 512x512 with circular or squircle adaptive masks.
AndroidManifest.xml Security & Permission Linter
Audit AndroidManifest.xml for exported activities, cleartext HTTP traffic vulnerabilities, dangerous permissions, and Google Play compliance warnings.
Android Keystore Fingerprint & Key Hash Studio
Compute Base64 App Signing Key Hashes for Facebook SDK, Google Sign-In, and Firebase from SHA-1 certificate fingerprints.