Skip to content Skip to sidebar Skip to footer

Failed To Resolve: Com.android.support:support-v13:26

Everything has been working and compiling fine until I've added a TabLayout to an .xml layout. After I added it, the project just refused to compile and either all of my .xml files

Solution 1:

If your compile SDK version is 26, android support dependencies version should be 26.x.x

Set your gradle dependencies as follow:

dependencies {
    compile fileTree(include: ['*.jar'], dir: 'libs')
    androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
       exclude group: 'com.android.support', module: 'support-annotations'
    })
    compile'com.android.support:appcompat-v7:26.0.1'compile'com.android.support:support-v13:26.0.1'compile'com.android.support.constraint:constraint-layout:1.0.2'
    testCompile 'junit:junit:4.12'compile'com.android.support:design:26.0.1'
}

If you still get compile errors, add google maven repository to Project Gradle file:

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

Solution 2:

Try below dependency in gradle and rebuild project;

compile'com.android.support:appcompat-v7:26.0.1'compile'com.android.support:support-v13:26.0.1'compile'com.android.support:design:26.0.1'

Solution 3:

This support library should not use a different version (25) than the compileSdkVersion (26)

means you have to update your support library from version 25 to 26 and problem will get resolved.

Post a Comment for "Failed To Resolve: Com.android.support:support-v13:26"