Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to completely remove node.js from Windows

I uninstalled my previous version of node.js (0.8.11) and downloaded the latest, 0.10.24 from the node.js website and installed it. However, after running node --version, it still indicates that I'm running v0.8.11. Obviously, some stuff was left behind during the uninstall process, and it's causing me to have all sorts of errors when trying to add modules through npm. I've seen solutions to this for OSX and Linux, but couldn't find anything for Windows. I'm running Windows 7 64-bit.

like image 891
Andrew De Forest Avatar asked Dec 20 '13 20:12

Andrew De Forest


People also ask

How do I completely remove Node from Windows?

Go to the windows control panel and click on Uninstall a program , select Node. js and click on uninstall tab to uninstall the node and npm successfully. Restart your system.

How do I completely uninstall npm?

To completely uninstall node + npm is to do the following: go to /usr/local/lib and delete any node and node_modules. go to /usr/local/include and delete any node and node_modules directory. if you installed with brew install node, then run brew uninstall node in your terminal.


1 Answers

How to remove Node.js from Windows:

  1. Take a deep breath.

  2. Run npm cache clean --force

  3. Uninstall from Programs & Features with the uninstaller.

  4. Reboot (or you probably can get away with killing all node-related processes from Task Manager).

  5. Look for these folders and remove them (and their contents) if any still exist. Depending on the version you installed, UAC settings, and CPU architecture, these may or may not exist:

  • C:\Program Files (x86)\Nodejs
  • C:\Program Files\Nodejs
  • C:\Users\{User}\AppData\Roaming\npm (or %appdata%\npm)
  • C:\Users\{User}\AppData\Roaming\npm-cache (or %appdata%\npm-cache)
  • C:\Users\{User}\.npmrc (and possibly check for that without the . prefix too)
  • C:\Users\{User}\AppData\Local\Temp\npm-*
  1. Check your %PATH% environment variable to ensure no references to Nodejs or npm exist.

  2. If it's still not uninstalled, type where node at the command prompt and you'll see where it resides -- delete that (and probably the parent directory) too.

  3. Reboot, for good measure.

like image 189
brandonscript Avatar answered Sep 19 '22 18:09

brandonscript