Inyene Udo
Inyene Udo

Reputation: 123

"License for package Android SDK Build-Tools 30.0.2 not accepted"

I just installed Android Studio on a new device and during my first project I get this error:

License for package Android SDK Build-Tools 30.0.2 not accepted.

Please, what should I do?

Upvotes: 10

Views: 17808

Answers (3)

Ravina Bhayani
Ravina Bhayani

Reputation: 121

In Android Studio:

  • Go to Tools -> SDK Manager
    Tools > SDK Manager
  • Select Android SDK and then the SDK Tools tab
  • Mark the Google Play Licensing Library and click on OK to install it Android SDK - SDK Tools - Google Play Licensing Library

Now your error should be all gone, if not, restart your Android Studio.

Upvotes: 12

Utkarsh Nehwal
Utkarsh Nehwal

Reputation: 31

I got exactly same error on Windows 10 but above solution didn't work for me. As this error was specially pointing towards 30.0.2, I checked in Android Studio under Tools>>SDK Manager>> SDK Platforms and found that only latest Android 12.0(S) with API level 31 was installed. I checked Android 11.0(R) to install API level 30 and error got resolved. Screenshot for solution

Upvotes: 3

gtxtreme
gtxtreme

Reputation: 3566

For Linux

Go to Android\sdk\tools\bin

yes | sdkmanager --licenses

For MacOS

yes | sudo ~/Library/Android/sdk/tools/bin/sdkmanager --licenses

For Windows

cmd.exe /C"%ANDROID_HOME%\tools\bin\sdkmanager.bat --licenses" 

Make sure that Java is installed before hand

Credits to this answer

Upvotes: 3

Related Questions