I installed nodejs in C:\\Program Files (x86)\\nodejs
then I created a .js file and saved it in my desktop just to output \'hello world\' in the console:
Faced the same problem while trying to run node-red.
node /red. js
In my case it was :
node AppData/Roaming/npm/node_modules/node-red/red.js