Want to take your software engineering career to the next level? Join the mailing list for career tips & advice Click here


DEPRECATED Gradle plugin which downloads and manages your Android SDK.

Subscribe to updates I use sdk-manager-plugin

Statistics on sdk-manager-plugin

Number of watchers on Github 1448
Number of open issues 44
Average time to close an issue 16 days
Main language Groovy
Average time to merge a PR 11 days
Open pull requests 15+
Closed pull requests 10+
Last commit over 3 years ago
Repo Created over 6 years ago
Repo Last Updated over 2 years ago
Size 453 KB
Organization / Authorjakewharton
Page Updated
Do you use sdk-manager-plugin? Leave a review!
View open issues (44)
View sdk-manager-plugin activity
View on github
Fresh, new opensource launches 🚀🚀🚀
Software engineers: It's time to get promoted. Starting NOW! Subscribe to my mailing list and I will equip you with tools, tips and actionable advice to grow in your career.
Evaluating sdk-manager-plugin for your project? Score Explanation
Commits Score (?)
Issues & PR Score (?)


This plugin is deprecated and is no longer being developed. Tools and dependencies are automatically downloaded using version 2.2.0 of the Android Gradle plugin or newer.

SDK Manager Plugin

SDK missing? API level not downloaded? Support library out-of-date?

These are all typical problems which you shouldn't have to deal with. This is especially painful when you have multiple developers on a project or a CI machine that you have to keep up-to-date.

This Gradle plugin will manage these SDK dependencies for you automatically.

Supported functionality:

  • local.properties will be created if missing. The ANDROID_HOME environment variable will be used if present. Otherwise ~/.android-sdk will be used.
  • The platform-specific SDK will be downloaded if missing.
  • The build tools and platform tools will be downloaded if missing.
  • Compilation API declared in compileSdkVersion will be downloaded if missing.
  • If any dependencies are declared on support libraries, the support repository will be downloaded if missing. If the revision of the support repository does not contain the version declared it will be updated.
  • If any dependencies are declared on Google Play Services, the Google repository will be downloaded if missing. If the revision of the Google repository does not contain the version declared it will be updated.
  • If an emulator is specified, it will be downloaded if missing. If the emulator revision is less than the available revision, it will be updated.

Note: By using this plugin you acknowledge that associated licenses of the components downloaded are accepted automatically on your behalf. You are required to have accepted the respective licenses of these components prior to using this plugin.


Apply the plugin in your build.gradle before the regular 'android' plugin:

buildscript {
  repositories {
  dependencies {
    classpath 'com.android.tools.build:gradle:0.12.+'
    classpath 'com.jakewharton.sdkmanager:gradle-plugin:0.12.+'

apply plugin: 'android-sdk-manager'
apply plugin: 'com.android.application'

// optionally including an emulator
sdkManager {
  emulatorVersion 'android-19'
  emulatorArchitecture 'armeabi-v7a' // optional, defaults to arm

On an initial run, the output will look something like this:

$ ./gradlew clean assemble
Android SDK not found. Downloading...
SDK extracted at '/Users/jw/.android-sdk'. Writing to local.properties.
Build tools 20.0.0 missing. Downloading...
Compilation API android-19 missing. Downloading...
Support library repository missing. Downloading...
Google Play Services repository missing. Downloading...
Emulator version not installed or outdated. Downloading...

(normal execution output)

Your output likely will be different depending on the varying factors listed above. Subsequent runs will omit this output and proceed directly to normal execution.

How long does this plugin add to the build lifecycle? It currently takes about 100ms on average to check all of the above conditions. This cost is only paid when Gradle is setting up the model for the project. If you use the Gradle daemon or use Android Studio this only happens once.


Copyright 2014 Jake Wharton

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at


Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
See the License for the specific language governing permissions and
limitations under the License.
sdk-manager-plugin open issues Ask a question     (View All Issues)
  • about 4 years Toggle for "sys images"
  • over 4 years Any way to force sdk download to be https?
  • over 4 years If ANDROID_HOME or local.properties are set, SDK not downloaded, even if not present
  • over 4 years Add support for transitive dependencies from dependent libraries
  • over 4 years Android build tools version 23.0.2 not being downloaded.
  • over 4 years Plugin breaks with com.android.tools.build:gradle:2.0.0-alpha1
  • over 4 years Plugin doesn't download "Android Support Library" for support-annotations
  • over 4 years Add better error message with has trouble downloading parts of the SDK.
  • over 4 years Update NDK Option?
  • almost 5 years This project is dead or not ?
  • almost 5 years PackageResolver fails silently
  • almost 5 years Build fails even though library is updated
  • almost 5 years Cannot get plugin to use Http instead of Https
  • about 5 years Avoid downloading GMS & Support repositories
  • about 5 years Add ability to configure dependencies via sdkManager extension
  • about 5 years Next Release?
  • over 5 years Build tools 22.0.1 downloaded successfully but tools not executable
  • over 5 years Download NDK too
  • over 5 years Downloading target 22 doesn't work
  • over 5 years Snapshot auto-deploy
  • over 5 years Add interactive mode
  • over 5 years unknown package filter 'extra-google-m2repository - Fails to download google play services
  • almost 6 years Plugin fails when one of android.[buildToolsVersion, ...] is null with NPE and no warning.
  • almost 6 years Build tools 20.0.0 never downloads...
  • almost 6 years Subprojects
  • almost 6 years Fails on first run, works on second
  • almost 6 years Update SDK tools before resolving dependencies
  • about 6 years Could not create plugin of type 'AppPlugin'
  • about 6 years Evaluate Abandoning Custom SDK Manager Integration for SDKLib
  • about 6 years Add Configuration Extension
sdk-manager-plugin open pull requests (View All Pulls)
  • Allow emulator download on non Android projects
  • Find indirect dependencies.
  • Add support for changing SDK Manager host and timeout
  • Make it possible to update SDK Tools by defining minSdkToolsVersion. Fixes issues #43 #14
  • Fix preview build tools availability check and download
  • Refactor to allow overriding SDK version and url
  • Groovydoc + Non-android projects + SdkResolverTest fix + com.jakewharton.sdkmanager plugin alias
  • Added method resolveTools() in order to update SDK Tools before reslving...
  • Update Sdk parameter
  • Always update Platform Tools and SDK Tools.
  • Always add maven support repository
  • pull sdk from http or https
  • Update to PR #87 ("Make it possible to update SDK Tools ..")
  • Add a note regarding build.gradle additions when using the Android Studio project layout
  • Always self-update the SDK tools before installing build tools
sdk-manager-plugin list of languages used
Other projects in Groovy