Error: npm v9.6.7 is known not to run on Node.js v18.17.0

I’ve created a react application on my laptop using node.js version 18.17.0 without using Node Version Manger then uploaded it to GitHub.

Next, I moved to a virtual PC that had NVM installed to do some development and pulled the project down from GitHub then reinstalled all the dependencies.

Sadly, I didn’t check to see which version of Nodejs was installed or active, I just tried to build the application. Took me a couple of minutes to realize that I was using Node.js version 10.17.0 instead of 18.17.0 that I needed.

I used NVM to install Nodejs version 18.17.0 and switch to it before building the application. I’m noting that to do the Nodejs version switching, I had to run the command line window as an administrator or else it didn’t work. Now we’re rolling.

Nope! Now we get the following error:

Error: npm v9.6.7 is known not to run on Node.js v18.17.0

In an attempt to solve this error, I’ve upgraded nvm from 1.1.7 to 1.1.10 but it didn’t solve my problem. The error persists.

[SOLUTION]

The following steps fixed the node.js version 18.17.0 and npm 9.6.7 issue that nvm was having.

Download nvm setup.exe for Windows version 1.1.11 from the link below and install which requires a reboot.

https://github.com/coreybutler/nvm-windows/releases

After reboot:

  • Log in as an Administrator
  • run command window as Administrator.
    • Run command: nvm uninstall 18.17.0
    • Run command: nvm install 18.17.0
    • Run command: nvm use 18.17.0
  • On the development VM run compile react application. Errors are now gone!

I sincerely hope this article has helped you as it took me a lot of effort to figure out.

~Cyber Abyss

Author: Rick Cable / AKA Cyber Abyss

A 16 year US Navy Veteran with 25+ years experience in various IT Roles in the US Navy, Startups and Healthcare. Founder of FinditClassifieds.com in 1997 to present and co-founder of Sports Card Collector Software startup, LK2 Software 1999-2002. For last 7 years working as a full-stack developer supporting multiple agile teams and products in a large healthcare organization. Part-time Cyber Researcher, Aspiring Hacker, Lock Picker and OSINT enthusiast.