Problem with npm start (error : spawn cmd ENOENT) Problem with npm start (error : spawn cmd ENOENT) windows windows

Problem with npm start (error : spawn cmd ENOENT)


Add C:\Windows\System32 to the global PATH environment variable.


Solution 1

Set your environment variable to C:\Windows\System32 . This works for me.

Sets System variable

Solution 2


If the first one doesn't work follow the 2nd steps. Navigate to your project folder and type this command >>>

rm -rf node_modulesrm package-lock.jsonrm  yarn.locknpm cache clear --forcenpm install

Solution 3

Downgrade react-scripts in package.json file


I had the same problem after I tried to install Mongo DB. I found out that this problem only exists with react-scripts@3.0.0. Try to reinstall your npm with a different react script version. Simply go to your folder in command and reinstall like this:

npm install react-scripts@2.1.8npm start

After that the app worked for me again.