Solving node is not recognized as an internal or external command

Article By Digamber Rawat Published on

node is not recognized as an internal or external command

Have you ever got this node error “node is not recognized as an internal or external command”? I got into the problem when i found this node error in my command line. This error message can be daunting. I searched the Internet and came to find out that the problem is this node executable was not in my PATH. It was missing for sure.

DigitalOcean Affiliate

So I added the node to the path and then restarted the visual studio only to see that the application is working once again. Here are the steps that you will need to follow to get rid of the “the node executable was not in my PATH” error.

  • Open control panel => system & security => system => advanced system settings => environment variables
  • In “User variables” or “System variables” look for variable PATH and include Node JS folder path. Often it is C:\Program Files\nodejs folder;. If you don’t get variable, then don’t hesitate to create it
  • Restart your personal computer

The executable code for the application must be present in the C:\Program Files\nodejs folder. If you want to check your PATH, then you can quickly check it by right-clicking on the My Computer in File Explorer and then select Advanced System Settings.

Once the dialog window opens you need to visit the Advanced tab, and at the very end you will find the Environment Variables button.

Environment Variables

Just tap on the button and the dialog variables will come up and it will include your system’s PATH variable. Now, make sure that the node path is included if it has not yet been added already.

PATH variable

Once you have done that, restart the Visual Studio or once again open a new command prompt. In the word bar, enter 'node -v' to copy the node version which is already installed. Another way to enter the PATH to any other application is directly from the command line.

Open the command line and type, assuming this is your original path, “SET PATH=C:\Program Files\Nodejs;%PATH%”.

So these are a few ways to avoid the “the node executable was not in my PATH” error. I hope this will surely help you out and feel free to comment down below with your feedback.

Digamber Rawat
Digamber Rawat

I am a software engineer from India, love to learn and write about latest web and mobile technologies like: MongoDB, Angular 2+, Firebase, Express JS, Python, Node JS, JavaScript, RxJS etc.