How to fix message in Android Studio 4.2 to remove jcenter() and migrate to mavenCentral()

Android Studio 4.2 displays below message.
Please remove usages of jcenter() Maven repository from your build scripts and migrate your build to other Maven repositories. This repository is deprecated and it will be shut down in the future.

To fix it, open the gradle file at the project level, search and and replace jcenter() with mavenCentral().

Although code will compile without changing jcenter() to mavenCentral() a of now, from February 2022, jcenter() will no more work. Therefore, the change needs to be done in all gradle files now.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s