Updated on 2026-01-08 GMT+08:00

Could not find method google()

Symptoms

After the Gradle plug-in is upgraded to version 3.0, the corresponding Gradle needs to be upgraded to version 4.1. If Gradle 4.1 is not found, the following error is displayed:

Could not find method google() for arguments [] on repository container

Solution

Use Gradle v4.1 or later versions.