28

I've just downloaded Android Studio 3 for Windows from the official website, but when it starts, it displays an error message about a missing Android SDK:

Android SDK missing. You can obtain it from d.android.com/sdk

When I click that link, it just redirects to the same official website. There isn't a separate link there for SDK download.

Where could I get it from? Shouldn't the Android SDK be installed during Android Studio 3 setup?

Attila Tanyi
  • 4,904
  • 5
  • 27
  • 34
  • Why not to download sdk seprately and give path there – Akash kumar Oct 26 '17 at 20:25
  • It nay happened after install new version and not import setting from previous version . but what happen if select `SDK`(path) manually? – Saeid Oct 26 '17 at 21:09
  • 1
    @Akashkumar - That's exactly what I'd like to do. But I don't know how to download the SDK separately. – Attila Tanyi Oct 27 '17 at 00:08
  • https://developer.android.com/studio/index.html see in last of page or search page with " sdk-tools-windows-3859397.zip " or download the studio and install the SDK it will be created in another folder – Akash kumar Oct 28 '17 at 09:03
  • 1
    @Akashkumar: initially followed these steps but that didn't work. It only installs the **tools** directory and AS was still complaining about the missing SDK stuff. The only solution forward is the one given by AttilaTanyi below. – GeertVc Jan 28 '18 at 09:36

10 Answers10

47

Apparently, the problem was that Android Studio 3.0 had already been installed and uninstalled before this. The SDK got removed, but Android Studio's config didn't.

Removing the config from a previous install (C:\Users\<user>\.AndroidStudio3.0 folder) did the trick. When Android Studio started up, it opened a dialog about which parts of the SDK to download, and then proceeded as expected.

Attila Tanyi
  • 4,904
  • 5
  • 27
  • 34
4

This happened with me on Windows 10 with Android Studio 3.1. The SDK was missing & I couldn't download or install it with the IDE. Android Studio wasn't downloading or installing the SDK properly, despite going through the steps. An error would appear at the end of the SDK configuration wizard telling me the SDK hadn't been installed b/c the sdk/tools directory didn't exist (no sh1t sherlock). I had not previously downloaded or installed Android Studio or the SDK.

It turns out that Android Studio 3.1 didn't have option checked for 'Enable embedded Maven repository' in the IDE Preferences.

After enabling the embedded Maven repo & restarting Android Studio, the SDK configuration wizard started up & successfully downloaded/installed the SDK.

wooldridgetm
  • 2,500
  • 1
  • 16
  • 22
  • rats. after a thorough search my copy of Android Studio doesn't have a IDE Preferences menu. – omikes Oct 08 '18 at 16:56
2

It's simple:

  • Select SDK Manager from the Tools menu in Android Studio.
    It will open a window called "Settings for New Projects".
    enter image description here

  • Click on Android SDK then select the Android SDK you want to download.
    enter image description here

This will definitely work.

Ola Ström
  • 4,136
  • 5
  • 22
  • 41
raghav
  • 21
  • 2
1

try to reinstall it and download(automatically downloaded) the required file after restart, but follow the steps

1 go to your main drive(consider 'c') then c/user//androidstudioproject and copy it to some other location(save your old projects to safe location)

2 uninstall android studio from control panel

3 delete following file

    a c/user/<your system name>/androidstudioproject

    b c/user/<your system name>/.android

  c 'c/user/<your system name>/AppData/Local/Android (keep hidden files on)'

4 now install your androidstudio from its setup

these will automatically download the required files after installation (always connect to internet while installing)

  • Thanks for the answer! These steps didn't solve the problem, but helped moving in the right direction. Removing the config from a previous install (`Users//.AndroidStudio3.0` folder) did the trick. – Attila Tanyi Oct 27 '17 at 00:14
1

I uninstalled Android Studio from Control Pannel. Save in a safe place the folder and subfolders below C:\USERS\MYNAME\ANDROIDSTUDIOPROJECTS

After I deleted c:\users\MYNAME\.ANDROIDSTUDIO3.1 AND c:\users\MYNAME\.ANDROID

After all I installed android studio. Take a long time but it resolved the problem.

Nic3500
  • 8,144
  • 10
  • 29
  • 40
1

If you're on MacOS, the Android Studio installer puts the bundled SDK files into ~/Library/Android/sdk/

kip2
  • 6,473
  • 4
  • 55
  • 72
1

by thanks from @Harsh.jaiswal

just delete this files:

 1. c/user/<your system name>/androidstudioproject
 2. c/user/<your system name>/.android
 3. c/user/<your system name>/AppData/Local/Android (keep hidden files on)

So AS will automatically download the required files

roghayeh hosseini
  • 676
  • 1
  • 8
  • 21
0

You can download sdk tools separately.

https://developer.android.com/studio/#downloads
Go to this link and download the sdk tools from under "Command line tools only".

after download, extract the zip file and move it to C:\Users\USERNAME\AppData\Local\Android\Sdk

If not worked, change sdk location from android studio

Shadow
  • 71
  • 2
  • 5
0

I ran into this and after uninstall and reinstall, still could not find the option under Tools.

After I opened a project, I found the option. There is a button (fourth from the right) that is the SDK Manager.

bjones01001101
  • 1,071
  • 1
  • 12
  • 21
0

I had to manually create
C:\Users\[USERNAME]\AppData\Local\Android\Sdk

and then I downloaded the tools from Command Line Tools Only section on: https://developer.android.com/studio/#downloads

then I extracted the files to:
C:\Users\[USERNAME]\AppData\Local\Android\Sdk

Hope this helps someone.

Valy Dia
  • 2,781
  • 2
  • 12
  • 32