ionic build Android | error: No installed build tools found. Please install the Android build tools ionic build Android | error: No installed build tools found. Please install the Android build tools android android

ionic build Android | error: No installed build tools found. Please install the Android build tools


I fix this by downloading sdk package called platform-tools and buid-tools using sdkmanager. You can use sdkmanager.exe or if you are using SDK CLI, go to ~\AppData\Local\Android\sdk\tools\bin and run this command:

sdkmanager "platform-tools" "platforms;android-26"

or

sdkmanager "build-tools;27.0.3"

or both

After that you should be able to run ionic cordova run android or ionic build android.

Note: globalize sdkmanager command by adding ~\AppData\Local\Android\sdk\tools and ~\AppData\Local\Android\sdk\tools\bin to your environment variable.


For me running these three commands fix the issue on my Mac:

export ANDROID_HOME=~/Library/Android/sdkexport PATH=${PATH}:${ANDROID_HOME}/toolsexport PATH=${PATH}:${ANDROID_HOME}/platform-tools

For ease of copying here's one-liner

export ANDROID_HOME=~/Library/Android/sdk && export PATH=${PATH}:${ANDROID_HOME}/tools && export PATH=${PATH}:${ANDROID_HOME}/platform-tools

To add Permanently

Follow these steps:

  1. Open the .bash_profile file in your home directory (for example, /Users/your-user-name/.bash_profile) in a text editor.
  2. Add export PATH="The above exports here" to the last line of the file, where your-dir is the directory you want to add.
  3. Save the .bash_profile file.
  4. Restart your terminal

Adding to bash process for different systems


You are missing android SDK tools. Please try the following:

android list sdk --allandroid update sdk -u -a -t <package no.>

Where <package no.> is 1,2,3,n and

-u (--no-ui)  # Headless mode-a (--all)    # Includes all packages (also obsolete ones)-t (--filter) # Filter by package index