I already installed ganache as:


   C:\Users\Henry Alberto\Desktop\GenerativeArtPython>npm install -g ganache-cli
   C:\Users\Henry Alberto\AppData\Roaming\npm\ganache-cli -> C:\Users\Henry 

 > [email protected] install C:\Users\Henry Alberto\AppData\Roaming\npm\node_modules\ganache- 
 > node-gyp-build || exit 0

 > [email protected] install C:\Users\Henry Alberto\AppData\Roaming\npm\node_modules\ganache- 
 > node-gyp-build || exit 0

 + [email protected]
 added 101 packages from 182 contributors in 13.55s` 

but when I call it on terminal I get: 'ganache-cli' is not recognized as an internal or external command, operable program or batch file.

C:\Users\Henry Alberto\Desktop\GenerativeArtPython>ganache-cli
'ganache-cli' is not recognized as an internal or external command,
operable program or batch file.

I have tried to run it with vsc using cmd, bash and powershell. I also added 'ganache-cli' to my environment variables but it still throws the same error. I checked ganache was added to npm folder

C:\Users\Henry Alberto\AppData\Roaming\npm

Any clue? Thanks beforehand.

  • Why are u using cli :)? Use the app much easier with nice interface ?
    – Majd TL
    Commented Aug 27, 2021 at 18:59
  • Yes, you are right, but sometimes I prefer cli. I was using it last month and it worked nicely every time. Commented Aug 27, 2021 at 19:57

1 Answer 1


Hey I know it is too late ..but this might help others facing the same issue The error is because Ganache CLI is not added to your system's PATH variable.

Here are the steps to add Ganache CLI to your system's PATH variable:

  1. Open the Start menu and search for "Environment Variables."
  2. Click on "Edit the system environment variables."
  3. Click on the "Environment Variables" button at the bottom right of the System Properties window.
  4. Under the "System Variables" section, scroll down and find the "Path" variable, then click "Edit."
  5. Click "New" and enter the path to the folder where you installed Ganache CLI (e.g., "C:\Program Files\Ganache-Cli").
  6. Click "OK" on all the windows to close them.

Or else you can do the same with npm and it works like a charm :

npm install -g ganache-cli
  • Thank you, I was able to solve it, but I forgot to post the explanation here. Thanks for the steps above. Commented Apr 12, 2023 at 12:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.