flutter doctor warns that dart on your path is not in the Flutter SDK
Warning: `dart` on your path resolves to C:\dart-sdk\bin\dart.exe, which is not inside your current Flutter SDK checkout at C:\flutter.Short answer
flutter doctor found a dart program on your PATH that lives outside the Flutter SDK folder, usually a separate Dart SDK installed earlier in the list. Put the Flutter bin folder at the front of PATH, open a new terminal, and confirm that dart now comes from Flutter.
Fix it fast
1Find out which cause you have
List every dart on PATH in order. The first one is what runs. If it is not under your Flutter folder, the warning is correct.
where dart # Windows which -a dart # macOS and Linux2Match what you see, then jump to its fix
- 1
The first line of where or which -a points at a standalone Dart folder, not flutter/binA separate Dart SDK comes before flutter/bin on PATHFix - 2
You already edited PATH but where or which -a still shows the old orderThe terminal or IDE was not restarted after the changeFix - 3
The warning names a Flutter path you did not expect, for example an old cloneflutter on PATH belongs to a different Flutter checkoutFix
- 1
What does the error look like?
Warning: `dart` on your path resolves to C:\dart-sdk\bin\dart.exe, which is not inside your current Flutter SDK checkout at C:\flutter.Consider adding C:\flutter\bin to the front of your path.
Cause 1 of 3
A separate Dart SDK comes before flutter/bin on PATH
1Check
Flutter ships its own Dart inside the SDK. If another Dart SDK folder is earlier in PATH, the shell uses that one, and flutter doctor reports it with the advice to move the Flutter bin folder to the front.
flutter doctor -v
echo $PATH # use: echo %PATH% in cmd.exe2Fix
Move the Flutter bin folder to the top of PATH. On Windows, edit the user Path in Environment Variables and use Move Up until the Flutter entry is first. On macOS or Linux, put it before $PATH in your shell profile.
# macOS (~/.zprofile) or Linux (~/.bashrc)
export PATH="$HOME/develop/flutter/bin:$PATH"3Verify
Open a new terminal. dart now resolves inside the Flutter folder and flutter doctor no longer prints the warning.
which -a dart
flutter doctorConfirmed by docs.flutter.dev
Cause 2 of 3
The terminal or IDE was not restarted after the change
1Check
A running terminal keeps the PATH it started with. The Flutter guide says to close and reopen all terminal sessions and IDEs after changing it.
echo $PATH # compare with the value you saved in the profile2Fix
Close every terminal and the IDE, then open them again. On macOS and Linux a new session reads the profile file again.
# close and reopen the terminal, then:3Verify
The order shown by which -a now matches the profile.
flutter --version && dart --versionConfirmed by docs.flutter.dev
Cause 3 of 3
flutter on PATH belongs to a different Flutter checkout
1Check
The same check runs for the flutter command, so it can point at another copy of the SDK than the one whose doctor you are running.
where flutter # Windows
which -a flutter # macOS and Linux2Fix
Keep one Flutter folder on PATH, in front, and remove the entry of the old one.
# shell profile: keep only this line for Flutter
export PATH="$HOME/develop/flutter/bin:$PATH"3Verify
One flutter and one dart are listed, both inside the same folder.
which -a flutter
which -a dartConfirmed by docs.flutter.dev
How do I stop it coming back?
- Do not install a separate Dart SDK next to Flutter. Use the dart command that comes with Flutter.
- Keep exactly one Flutter folder on PATH.
- After any PATH change, restart terminals and the IDE.
Sources
How was this page made?
I drafted this page with AI assistance from the official documents listed under Sources. Every cause above names the document that confirms it. I have not reproduced this fix on a machine of my own yet, so read it as documented guidance, not a test report. Found a mistake? Tell me.
Which stack is behind this page?
Projects of mine built on the same technologies:
- TaxiDexMy own multi-tenant taxi dispatch SaaS: API, dispatcher portal, driver and passenger apps, and the servers underneath.
- Qist BazaarA buy-now-pay-later marketplace built from a blank repo, now past 100K downloads on Google Play.
- SessionBirdAn omnichannel engagement suite in Flutter: campaigns, chatbot, tickets, analytics and live calling.
Related fixes
Mobile apps
Terminal says pub: command not found after installing Dart
dart: command not found
The standalone pub program no longer exists in current Dart.
2 causes, each with a fixMobile apps
The terminal cannot find the flutter or dart command
zsh: command not found: flutter
The flutter and dart programs both live in the bin folder of the Flutter SDK, so one PATH entry gives you both.
3 causes, each with a fixMobile apps
flutter doctor fails the Network resources check
A cryptographic error occurred while checking
The Network resources check sends a request to a fixed list of hosts and fails if one does not answer.
2 causes, each with a fixMobile apps
A Flutter command says it cannot find pubspec.yaml
This command should be run from the root of your Flutter project.
Flutter and Dart read pubspec.yaml from the current working directory.
3 causes, each with a fixMobile apps
Flutter keeps retrying 'pub upgrade' for its own tool
Got socket error trying to find package
The flutter command rebuilds its own tool and downloads packages from pub.dev to do it.
3 causes, each with a fixMobile apps
Terminal says fvm: command not found after installing FVM
zsh: command not found: fvm
The shell cannot find an fvm executable.
2 causes, each with a fix