Android Gradle plugin 9.1.0 (March 2026)

Android Gradle plugin 9.1 is a minor release that includes a variety of new features and improvements.

Compatibility

The maximum API level that Android Gradle plugin 9.1 supports is API level 36.1. Here is other compatibility info:

Minimum version Default version Notes
Gradle 9.3.1 9.3.1 To learn more, see updating Gradle.
SDK Build Tools 36.0.0 36.0.0 Install or configure SDK Build Tools.
NDK N/A 28.2.13676358 Install or configure a different version of the NDK.
JDK 17 17 To learn more, see setting the JDK version.

R8 changes

The following R8 changes are included in AGP 9.1.0.

Enable repackaging to unnamed (default) package when compiling to DEX

R8 now repackages classes into the unnamed (default) package when compiling to DEX by default. This effectively adds the rule -repackageclasses to builds that use neither -flattenpackagehierarchy or -repackageclasses explicitly.

Repackaging by default ensures consistency with obfuscation, optimization and shrinking, which are all opt-out rather than opt-in, and thereby mitigates suboptimal configurations that are not explicitly opting in to repackaging.

In order to opt out of this behavior, use the new -dontrepackage rule.

Support named levels for -maximumremovedandroidloglevel

When using -maximumremovedandroidloglevel, you can now specify the log level names instead of the numbers. The following table shows the names and the corresponding numeric log level.

Name Level
ASSERT 7
ERROR 6
WARN 5
INFO 4
DEBUG 3
VERBOSE 2
NONE 1

You must specify the log level names in all caps.

Fixed issues

Android Gradle plugin 9.1.0-rc01

Fixed Issues
No public issues were marked as fixed in AGP 9.1.0-rc01

Android Gradle plugin 9.1.0-alpha09

Fixed Issues
Lint
Lint in Otter.2 does not recognize the new compileSdk and targetSdk DSL from AGP 9.0

Android Gradle plugin 9.1.0-alpha08

Fixed Issues
Android Gradle Plugin
Clean Project menu runs a sub-project target instead of just "clean"
Incremental dex desugaring bug in AGP
Config cache: avoid accessing task extensions and conventions at execution time
AGP does not know about canary platforms and complains
Lint Integration
Android Lint using K1 when applied to a java-library project
"Lint check for lint checks" not running

Android Gradle plugin 9.1.0-alpha07

Fixed Issues
Android Gradle Plugin
beforeVariants for KMP needs to be implemented.

Android Gradle plugin 9.1.0-alpha06

Fixed Issues
No public issues were marked as fixed in AGP 9.1.0-alpha06

Android Gradle plugin 9.1.0-alpha05

Fixed Issues
Android Gradle Plugin
AGP 9.0.0-rc01 doesn't resolve Kotlin libraries via kotlin() function

Android Gradle plugin 9.1.0-alpha04

Fixed Issues
Android Gradle Plugin
`*.xml.flat` files contain absolute file paths

Android Gradle plugin 9.1.0-alpha03

Fixed Issues
No public issues were marked as fixed in AGP 9.1.0-alpha03

Android Gradle plugin 9.1.0-alpha02

Fixed Issues
Android Gradle Plugin
Add ability to turn ManifestProcessorTask warnings into errors

Android Gradle plugin 9.1.0-alpha01

Fixed Issues
Android Gradle Plugin
Add ability to turn ManifestProcessorTask warnings into errors
Transforming `OBFUSCATION_MAPPING_FILE` artifact results in outputs of R8 task missing from the output folder

Android Gradle plugin 9.1.0

Fixed Issues
No public issues were marked as fixed in AGP 9.1.0