“Failed to resolve: com.android.support:support-v4:26.0.0” and other similar errors on Gradle sync [duplicate]

I don’t have an Android wear project, but I had the same problem when I wanted to upgrade the Support Library version for an existing project to 26.0.0. Since 26.0.0 the support libraries are available through Google’s Maven repository. So I had to add the repository to my build. gradle file.

allprojects {
  repositories {
      jcenter()
      maven {
          url "https://maven.google.com"
      }
  }
}

Check out https://developer.android.com/topic/libraries/support-library/setup.html for more details.

Leave a Comment