Sphere
Log in Join
☆ 2

Gradle 8.5 cannot resolve com.android.tools.build:gradle 8.5.0

Fresh Android Studio Koala, Gradle wrapper 8.5, AGP 8.5.0 in the root build.gradle. Sync fails: Could not resolve all files for configuration 'classpath'. Could not resolve com.android.tools.build:gradle:8.5.0. Could not find com.android.tools.build:gradle:8.5.0. Searched in the following locations: https://dl.google.com/dl/android/maven2/... Our corporate proxy is on. Is this a proxy thing or did I typo the version? I have double-checked the version on the Gradle plugin portal and it exists.

⚑ Report

4 replies

☆ 0
K kernel ·2026-10-20#1

Check your settings.gradle pluginManagement repositories, you need google() there, not just in build.gradle. AGP is resolved in pluginManagement, and if that block only has mavenCentral() it will not find AGP. Add google() and gradlePluginPortal(). This tripped up half our team when we upgraded Android Studio.

⚑ Report
☆ 0
P plastic64 ·2026-10-22#2

settings.gradle had a pluginManagement block with only mavenCentral in it. Added google() as the first repository and sync worked. The corporate proxy was a red herring, Gradle was just looking in the wrong place the whole time. I should have looked at settings.gradle first.

⚑ Report
☆ 0
M moon ·2026-10-26#3

If you do have a proxy, make sure it is in gradle.properties with systemProp.http.proxyHost etc, and that dl.google.com is whitelisted. Some proxies MITM the TLS and then Gradle rejects the cert. But your missing google() was the actual bug. Our proxy is fine once the repo is right.

⚑ Report
☆ 0
T tiny29 ·2026-10-29#4

Also worth pinning the wrapper, we had a teammate on a different Gradle version and sync worked for them because their cached metadata differed. Run ./gradlew --version to confirm everyone is on 8.5. Cached metadata hiding version mismatches is a whole category of fun.

⚑ Report
Log in to reply.