Maaz Zindani

Loading the index…

↑↓ move↵ openesc close4072 pages
Flutter and app store releases

flutter doctor fails in Command Prompt or PowerShell on Windows

Error'flutter' is not recognized as an internal or external command operable program or batch file

Short answer

On Windows the usual causes are that flutter\bin is not on PATH, the terminal was opened before PATH changed, the SDK sits in a protected folder such as Program Files, or PowerShell blocks the helper script. Fix PATH, move the SDK to a user-writable folder, and reopen the terminal.

  • Applies to Flutter 3.35, Windows 11, PowerShell 7, Command Prompt
  • Updated
  • By Maaz Zindani, Senior Software Engineer

Fix it fast

  1. 1Find out which cause you have

    Ask Windows where it finds flutter. If nothing is printed, the SDK is not on PATH for this terminal.

    where.exe flutter
  2. 2Match what you see, then jump to its fix

    1. 1'flutter' is not recognized as an internal or external commandflutter\bin is not on PATHFix
    2. 2The Flutter SDK is installed in a protected folder and may not function correctly.The SDK is in a protected folderFix
    3. 3Invoke-Expression : You cannot call a method on a null-valued expression (update_engine_version.ps1)PowerShell fails inside the engine version scriptFix
    4. 4Git was never installed on this machine (git --version is not recognized)Git for Windows is missingFix

What does the error look like?

  • 'flutter' is not recognized as an internal or external command operable program or batch file
  • The Flutter SDK is installed in a protected folder and may not function correctly.
  • Invoke-Expression : You cannot call a method on a null-valued expression

Cause 1 of 4

flutter\bin is not on PATH

1Check

The SDK's bin folder has to be a Path entry in your user variables, and the terminal has to be opened after the change.

where.exe flutter
echo %PATH%

2Fix

Open Advanced System Settings, then Environment Variables. In User variables edit Path (or create it) and add the SDK's bin folder, for example %USERPROFILE%\develop\flutter\bin. Move it to the top of the list. Close and reopen every terminal and IDE.

%USERPROFILE%\develop\flutter\bin

3Verify

Both tools answer in a new terminal.

flutter --version
dart --version

Confirmed by docs.flutter.dev

Did this fix it?

Cause 2 of 4

The SDK is in a protected folder

1Check

Folders such as C:\Program Files need administrator rights to write to, and Flutter updates itself inside its own folder.

where.exe flutter

2Fix

Move the SDK to a folder you can write to without administrator permission, such as C:\src\flutter, update the Path entry to match, and restart the terminal.

C:\src\flutter\bin

3Verify

flutter doctor starts without the protected-folder warning.

flutter doctor

Confirmed by docs.flutter.dev

Did this fix it?

Cause 3 of 4

PowerShell fails inside the engine version script

1Check

The Flutter troubleshooting page lists this for flutter doctor in PowerShell. Confirm that the SystemRoot variable is set; it is normally C:\Windows.

echo $env:SystemRoot

2Fix

Run PowerShell as Administrator and try again. If it still fails, allow locally created scripts for your user.

Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser

3Verify

Open a new PowerShell window and run the doctor.

flutter doctor

Confirmed by docs.flutter.dev

Did this fix it?

Cause 4 of 4

Git for Windows is missing

1Check

The install guide asks for Git for Windows before the SDK is extracted.

git --version

2Fix

Install the latest Git for Windows, reopen the terminal, and run the doctor again.

# download the installer from https://git-scm.com/downloads/win

3Verify

git answers and the doctor shows a result for Flutter.

git --version
flutter doctor

Confirmed by docs.flutter.dev

Did this fix it?

How do I stop it coming back?

  • Extract the SDK once into a path without spaces and without administrator rights.
  • Set PATH through the Environment Variables dialog, then reopen terminals and IDEs.
  • Keep Git for Windows installed and current.

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:

Related fixes

Mobile apps

Google Play says the app does not support 16 KB memory pages

check_elf_alignment.sh reports UNALIGNED for a library under lib/arm64-v8a

Google Play requires apps that target Android 15 or higher and ship native .so libraries to run on devices with 16 KB memory pages; from 1 February 2027 it will block updates that do not.

5 causes, each with a fix

Next step

Want this handled for good?

I look after servers, apps and releases end to end. Tell me what keeps breaking.