This article will tell you everything you need to know to deal with all those crazy version rules. Everything will come with source (a.k.a. answers on StackOverflow) if necessary.

  1. minSdkVersion ≤ targetSdkVersion (dah)
  2. targetSdkVersion ≤ compileSdkVersion
  3. support libraries version = compileSdkVersion
  4. compileSdkVersion ≤ buildToolsVersion
  5. support libraries version ≤ buildToolsVersion (by combining no. 3 and no. 4)
  6. click and scroll down to see the mapping between Gradle Plugin version and Gradle version

TL;DR:

  1. minSdkVersion ≤ targetSdkVersion = support libraries version = compileSdkVersion ≤ buildToolsVersion
  2. Android Gradle Plugin depends on the Gradle version

Remark:

  1. even though targetSdkVersion can be older than support libraries version & compileSdkVersion, it does not seems to be recommended, but I don’t know if there is anything that might break. If you have any experience/example/etc, let me know and I will update this document.
  2. the use of maxSdkVersion is generally discouraged
  3. Gradle Plugin nor Gradle depends on Android Studio version from what I can see, but they generally comes together, and if you upgrade to a newer version of Android Studio it will usually ask if you want to upgrade The Gradle Plugin to the newer version.

Quick Tech Support: all the different SDK/build/whatever version you need to use to build an…

This article will tell you everything you need to know to deal with all those crazy version rules. Everything will come with source (a.k.a…