nvm install windows: A practical guide for Windows users
Learn how to use nvm install windows to manage Node.js versions on Windows. This Install Manual guide covers setup, options like nvm-windows vs WSL, common commands, and best practices for reliable version control across projects.
Use nvm-windows to manage Node.js versions on Windows. Install the Windows-specific nvm-windows tool, then run nvm install <version> and nvm use <version> to switch between Node versions. Verify with node -v and npm -v. This quick path complements the full guide.
What is nvm install windows and why use it on Windows
Node.js version management is essential for testing across multiple releases and keeping projects portable. On Windows, the Unix-based nvm cannot run natively, so developers rely on a Windows-compatible port commonly referred to as nvm-windows. This approach provides a straightforward way to install, switch, and manage multiple Node.js versions without manually editing PATH or juggling installers for each project. Understanding how to use nvm install windows helps you avoid version conflicts, reduces setup time, and improves consistency across team environments. Install Manual emphasizes this workflow because it minimizes environment drift and makes it easier to reproduce builds. The section also highlights the limitations of Windows-native tooling and how the Windows port integrates with your shell of choice, whether PowerShell or CMD.
# Check baseline (only after Node installation or initial setup)
node -vAs you get started, keep in mind that this approach is designed to simplify version control for Node.js. It lets you lock a project to a specific version, switch versions quickly for testing, and decommission older builds cleanly. The goal is to provide a robust workflow that scales from small projects to multi-repo teams, without forcing you to reinstall Node for every change.
-1tocolinkhiddennull
Steps
Estimated time: 25-35 minutes
- 1
Validate prerequisites
Confirm you have Windows, admin rights, and internet access. Open a PowerShell or CMD session to verify you can run basic commands like dir or echo. This ensures the environment is ready for the nvm-windows installation.
Tip: Double-check you can run at least one shell as Administrator. - 2
Install the nvm-windows tool
Download and run the nvm-windows installer from the official repository. Follow the prompts to set up the directory structure and PATH entries. This is a one-time setup that enables the nvm commands you’ll use later.
Tip: If you prefer automation, consider using a package manager like Chocolatey to install the Windows package. - 3
Verify installation
Open a new shell and run nvm version or nvm list to confirm the tool is accessible and that PATH is updated correctly.
Tip: Restart the shell after installation to ensure PATH changes take effect. - 4
Install a Node.js version
Choose a version (for example 18.16.0) and install it with nvm install 18.16.0. This downloads the binary and registers it for use.
Tip: Use a specific version aligned with your project requirements. - 5
Switch active version
Activate the desired version with nvm use 18.16.0. This will affect the current shell session.
Tip: If you open new terminals, you may need to run the command again or set a default. - 6
Verify Node and npm
Check the active Node and npm versions to confirm the switch worked: node -v and npm -v.
Tip: Keep an eye on compatibility with your dependencies.
Prerequisites
Required
- Windows 10/11 or equivalentRequired
- Admin rights to install softwareRequired
- PowerShell or Command Prompt accessRequired
- Internet access to download the nvm-windows installerRequired
- Basic familiarity with CLI commandsRequired
Optional
- Optional: target Node.js versions for testingOptional
Commands
| Action | Command |
|---|---|
| Check installed versionsLists installed Node versions and the current default | nvm list |
| Install a specific versionInstall the requested Node.js version from the remote list | nvm install 18.16.0 |
| Switch to a versionMake this the active version for this shell | nvm use 18.16.0 |
| Set a default versionNew shells will start with this version | nvm alias default 18.16.0 |
Got Questions?
What is nvm install windows and why should I use it on Windows?
nvm install windows refers to using a Windows-compatible Node Version Manager (nvm-windows) to install and switch between Node.js versions. It simplifies testing across versions and keeps projects isolated without manual PATH edits. This approach is recommended for consistent environments across teams.
nvm on Windows helps you manage Node versions easily, so you can test across releases without manual PATH changes.
Can I use nvm-windows with Git Bash or PowerShell?
Yes. nvm-windows works from Windows shells such as PowerShell and CMD. Git Bash can also use nvm-windows if the PATH is configured correctly. Ensure you run the same shell where you installed nvm-windows.
Yes, you can use it from PowerShell or CMD, and Git Bash can work if PATH is set properly.
What if nvm is not recognized after installation?
This usually indicates PATH changes aren’t picked up by your shell. Open a new terminal, verify PATH entries, and restart the terminal. Reinstalling or repairing the PATH configuration often resolves the issue.
If nvm isn’t recognized, refresh your terminal or reinstall to fix PATH references.
How do I uninstall a Node.js version managed by nvm-windows?
Use nvm uninstall <version> to remove a specific version from the system. After uninstall, you may switch to another installed version with nvm use, or set a different default.
You can remove a version with a simple command and then switch to another version if needed.
Is it safe to run nvm in production environments?
nvm-windows is widely used for development and staging environments. For production, ensure version control, stable builds, and consistent deployment processes. Test pipelines should lock specific versions to avoid drift.
Using nvm in prod is possible if you strictly control versions and deployments.
What about per-project Node versions?
You can use a per-project version approach with a local .nvmrc file or a script that reads the version and runs nvm use accordingly. This ensures each project runs with its required Node version.
Per-project versioning helps keep each project isolated and consistent.
Main Points
- Install nvm-windows to manage Node versions on Windows
- Use nvm install and nvm use to switch versions
- Verify with node -v and npm -v after every change
- Keep the default version aligned with your most common project
- Use .nvmrc for per-project version declarations
