How To Uninstall Linux Apps On Chromebook How to Remove Node.js Completely from Your System There are no restrictions on the choice of programming languages for server-side code. Popular options include PHP, Ruby, C#, Python, and JavaScript. JavaScript stands out due to its beginner-friendliness and its ability to work on both the client-side and server-side.
Node.js, as the server-side runtime environment for JavaScript, enables the creation of scalable web applications. However, Node.js might not be suitable for all developers, especially those with different language backgrounds or preferences.
In this tutorial, we will guide you through the step-by-step process of completely uninstalling Node.js from your computer.
Prerequisites Before proceeding with the uninstallation, it’s crucial to ensure that Node.js is correctly installed on your system. The method for checking this varies depending on your operating system.
Checking Node.js Installation on Windows Using File Explorer:
- Open File Explorer and navigate to the C:/ drive.
- Look for the “Nodejs” folder in the directory where Node.js was originally installed.
- You can also check other locations for Node.js or npm files, such as:
- C:Program Files (x86)Nodejs
- C:Program FilesNodejs
- C:Users”user”AppDataRoamingnpm
- C:Users”user”AppDataRoamingnpm-cache If you find the Nodejs folder, it indicates that Node.js is correctly installed.
Using CMD:
- Search for “cmd” in the start menu, right-click it, and select “Run as administrator,” or press Win+R, enter “cmd,” and press Ctrl+Shift+Enter to open the command prompt as administrator.
- Run the following command:
css
node –version
- If you see a result like “v16.16.0,” it means Node.js is installed.
Checking Node.js Installation on Linux You can check if Node.js is installed by typing the following command in the Terminal:
node -v
The version number should appear in the terminal, such as “v16.16.0.”
Checking Node.js Installation on Mac
- Press command+space to open Spotlight Search.
- Type “Terminal” and press enter.
- Check if Node.js is installed by typing the following command in the Terminal:
node -v
- You should see the version of Node.js installed, like “v16.16.0.”
Uninstalling Node.js on Windows There are three methods to remove Node.js from Windows:
Method 1: Uninstalling from Windows Settings
- Go to Settings from the start menu.
- Click on the “Apps” section.
- In the “Apps & Features” section, enter “Nodejs” in the search box.
- Select the Nodejs application and click “Uninstall.”
- Restart your Windows machine (recommended).
- Open CMD as administrator and run:
css
node –version
- If you see no output, Node.js is successfully uninstalled.
Method 2: Uninstalling from Windows CMD
- Search for “cmd” in the start menu, right-click it, and select “Run as administrator,” or press Win+R, enter “cmd,” and press Ctrl+Shift+Enter to open the command prompt as administrator.
- Clear the npm cache by running:
css
npm cache clean –force
Go to the Windows control panel, select “Uninstall a program,” right-click on Nodejs, and uninstall it.
Run CMD as administrator and type:
css
node –version
- If you see no output, Node.js is successfully uninstalled.
Read More : How To Mount Sd Card Linux
Method 3: Uninstalling from Windows Registry
- Search for “Registry Editor” in the start menu and click on it, or press Win+R, enter “regedit,” and hit Enter to open the Windows Registry.
- Allow the app to make changes.
- Navigate to the path: ComputerHKEY_LOCAL_MACHINESOFTWARENode.js.
- Locate the Nodejs directory on the left sidebar, right-click it, and delete the directory.
- Restart your Windows machine (recommended).
- Open CMD as administrator and run:
css
node –version
- If you see no output, Node.js is successfully uninstalled.
Uninstalling Node.js on Ubuntu To uninstall Node.js on Ubuntu, follow these steps:
Step 1: Locating the Binary Files You can locate Node.js binaries and verify if they are uninstalled using commands like which or find.
Step 2: Uninstalling Node.js There are different methods to remove Node.js from Ubuntu, including manually deleting binaries, using apt or apt-get commands, and uninstalling specific versions using nvm.
Step 3: Removing Node.js Info from Source Lists Check for Node.js data in the /etc/apt/sources.list.d directory and remove it if present.
Step 4: Clearing the Cache Remove all node-related packages and configuration files using the purge command or manually remove hidden npm directories.
Step 5: Remove Unused Files Delete unused files and free up space on your computer.
Uninstalling Node.js on Mac You can uninstall Node.js from MacOS using various methods:
Method 1: Uninstalling Using Homebrew Use the terminal to uninstall all versions of Node.js with the brew uninstall –force node command, followed by brew cleanup to remove unused folders and dependencies.
Method 2: Uninstalling Using NVM Uninstall a specific version of Node.js with the nvm uninstall <version> command.
Method 3: Uninstalling Using Terminal Manually remove Node.js files and folders from specific directories on your Mac.
Method 4: Uninstalling Node Manually Manually delete Node.js files from various directories on your Mac.
Read More : What Is -I In Linux
Conclusion
These methods should help you successfully uninstall Node.js from your computer. If you need guidance on starting your coding journey, consider checking out resources like Codedamn for web development courses and blogs. Remember to practice coding regularly, and feel free to leave comments with suggestions or questions. You can also connect with me on Linkedin or Twitter if you’re interested in my content.