VISUAL STUDIO   Windows Mac

Where can I set my Android SDK locations?

PDF for offline use

Let us know how you feel about this

Translation Quality


0/250

last updated: 2017-11

In Visual Studio, navigate to Tools > Options > Xamarin > Android Settings to view and set the Android SDK location:

Example Locations tab in Preferences

The default location for each path is as follows:

  • Java Development Kit Location:

    C:\Program Files\Java\jdk1.8.0_131

  • Android SDK Location:

    C:\Program Files (x86)\Android\android-sdk

  • Android NDK Location:

    C:\ProgramData\Microsoft\AndroidNDK64\android-ndk-r13b

Note that the version number of the NDK may vary. For example, instead of android-ndk-r13b, it could be an earlier version such as android-ndk-r10e.

To set the Android SDK location, enter the full path of the Android SDK directory into the Android SDK Location box. You can navigate to the Android SDK location in File Explorer, copy the path from the address bar, and paste this path into the Android SDK Location box. For example, if your Android SDK location is at C:\Users\username\AppData\Local\Android\Sdk, clear the old path in the Android SDK Location box, paste in this path, and click OK.

In Visual Studio for Mac, navigate to Preferences > Projects > SDK Locations > Android. In the Android page, click the Locations tab to view and set the SDK location:

Example Locations tab in Preferences

The default location for each path is as follows:

  • Android SDK Location:

    ~/Library/Developer/Xamarin/android-sdk-macosx

  • Android NDK Location:

    ~/Library/Developer/Xamarin/android-ndk/android-ndk-r14b

  • Java SDK (JDK) Location:

    /usr

Note that the version number of the NDK may vary. For example, instead of android-ndk-r14b, it could be an earlier version such as android-ndk-r10e.

To set the Android SDK location, enter the full path of the Android SDK directory into the Android SDK Location box. You can select the Android SDK folder in the Finder, press CTRL+⌘+I to view folder info, click and drag the path to the right of Where:, copy, then paste it to the Android SDK Location box in the Locations tab. For example, if your Android SDK location is at ~/Library/Developer/Android/Sdk, clear the old path in the Android SDK Location box, paste in this path, and click OK.

Xamarin Workbook

If it's not already installed, install the Xamarin Workbooks app first. The workbook file should download automatically, but if it doesn't, just click to start the workbook download manually.