6

I added the steps provided by docs.
I also added Android SDK to the environmental variable but it's still remaining an issue.

I also tried these steps but it didn't work.

enter image description here

Also asked on https://github.com/flutter/flutter/issues/19805

9
  • 1
    That doesn't make sense. You show the output of flutter doctor and at the same time say "flutter is not recognized as n internal or external command". If it were not recognized you could not run flutter doctor. Why do you not post the output where the error is shown you used as question title. Or is the question actually about the Android SDK? Then please fix the title. Commented Jul 25, 2018 at 12:04
  • @GünterZöchbauer do you know how to fix this issue i updated my question Commented Jul 25, 2018 at 12:48
  • What do you get if your execute adb --version in a terminal? Commented Jul 25, 2018 at 12:55
  • Perhaps your Android Studio installation is not complete. Were you able to create an Android emulator as explained in flutter.io/setup-windows/#install-android-studio ? Commented Jul 25, 2018 at 12:57
  • ANDROID_HOME = G:\sdk; but Android SDK not found at this location. getting error like tis Commented Jul 25, 2018 at 13:13

6 Answers 6

24

For MAC:

AndroidStudio -> Preferences -> Appearance & Behavior -> System Settings -> Android SDK 
  1. choose the SDK Tools Segment
  2. Check the Android SDK Command-line tool (latest)

enter image description here

Sign up to request clarification or add additional context in comments.

3 Comments

After hours looking for it, this was the perfect solution. As simple as it is. Thanks for sharing. ;)
In the latest version of Android Studio, Preferences can be opened like this too: More Actions -> SDK Manager
this one is also working on windows 10. thank you mate
5

Please try adding

G:\sdk\tools and G:\sdk\platform-tools to the PATH environment variable.

3 Comments

What variable name for this two path in environment?
You can add them directly without a variable name.
i have added both sdk\tools and platform-tools to path wich doesn't work
1

See if it is configured this way in "Project Structure" enter image description here

It worked for me

Comments

0

It is little confusing. ANDROID_HOME location is not C:\Program Files\Android\Android Studio ANDROID_HOME location is C:\Users\username\AppData\Local

restart command prompt or Power Shell re-check flutter doctor

Comments

0

I was using Windows 10 and I encounter this issue. I had tried ANDROID_HOME to my path but it was not working because I was forget to add tools and build-tools in path variable. try this Open Edit the system Environment Setting(Search in Windows search).

  • Click on Environments Variable -> Create New variable -> Variable Name ANDROID_HOME and path your SDK path.
  • Double Tap on PATH or Edit it Add platform-tools,build-tools,tools (All folders are in Your SDK path)

Reopen Terminal and type Flutter Doctor

Done

Comments

0

Open Android studio, then go to appearance and behavior > system settings > android sdk. Then choose SDK Tools instead of the standard SDK Platforms guide. Then choose Android SDK Command-line tools (latest).

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.