You need Node.js on your Windows machine, a tutorial told you to run npm install, and the download page offers more choices than answers. This DevAnswers guide installs Node.js and npm on Windows 10 or 11 three ways, the installer, winget, and nvm-windows, explains which to pick and which version (LTS or Current), and fixes the two errors that catch almost every first-time Windows install.
Quick Answer: Install Node.js LTS in Two Minutes
- Download the LTS Windows installer (.msi) from nodejs.org and run it, accepting the defaults.
- Open a new PowerShell window (existing ones do not see the updated PATH).
- Verify both tools:
node -v
npm -v
There is no separate npm install: npm is the package manager for Node.js and it is installed alongside Node. If both commands print versions, you are done; the rest of this guide is for choosing versions and methods, and for when something does not print a version.
Which Method and Which Version?
| You are… | Use | Why |
|---|---|---|
| Installing Node for one project or tool | The MSI installer or winget | One system-wide Node, zero moving parts |
| Comfortable in the terminal, want scripted installs | winget | One command, upgrades via winget upgrade |
| A developer juggling multiple projects | nvm-windows | Install several Node versions, switch per project |
On versions: as of mid-2026, Node.js 24 is the Active LTS line and Node.js 26 is Current. LTS is the answer for production and for most people; Current is for trying the newest features and moves fast. The scheme itself is changing: through Node 26, odd-numbered releases (like 25) go unsupported after about six months while even-numbered ones become LTS, and starting with Node 27 the project moves to an annual cycle in which every major version reaches LTS. TL;DR: when in doubt, install LTS.
Method 1: The Windows Installer (MSI)
The classic route, and the right one for most single-version setups:
- On the nodejs.org download page, pick the LTS Windows installer (.msi, 64-bit).
- Run it. The defaults are correct for almost everyone, and the installer adds Node to your PATH.
- One wizard screen offers to automatically install the necessary tools for native modules (Python and the Visual Studio Build Tools). Most people should leave it unticked; you only need it for npm packages that compile C/C++ during install, and you can add the tools later if a package demands them.
- Finish, then open a new terminal and verify with
node -vandnpm -v.
Method 2: winget (Command-Line Install)
Windows 11 and current Windows 10 builds ship with the winget package manager, which turns the install into one line in PowerShell. If winget is not recognized on your machine (older Windows 10 builds and some restricted environments), update App Installer from the Microsoft Store, or simply use Method 1:
winget install OpenJS.NodeJS.LTS
Swap OpenJS.NodeJS.LTS for OpenJS.NodeJS if you want the Current line instead. Upgrading later is the standard winget flow:
winget upgrade OpenJS.NodeJS.LTS
As with the MSI, open a new terminal afterwards before verifying; winget installs update the PATH, but the window you ran the install from keeps its old environment.
Method 3: nvm-windows (Multiple Node Versions)
Projects age at different speeds, and sooner or later one of them needs an older Node than the rest. That is what a version manager solves, and Microsoft’s own Windows development docs walk developers through nvm-windows for exactly this job. Note the name: it is a separate project from the Linux/macOS nvm, purpose-built for Windows.
node your PATH finds, and the losers are you and your build. - Download
nvm-setup.exefrom the latest nvm-windows release and run it. - Open a new PowerShell window as Administrator (nvm-windows switches versions via a symlink in Program Files, which needs elevation) and install the LTS release:
nvm install lts - See what installed with
nvm list, then activate that exact version:nvm use <version>, substituting the number the list shows (for examplenvm use 24.4.1). - Confirm:
nvm listnow marks the active version, andnode -vanswers.
From here, nvm install any other version a project needs and nvm use to switch between them in seconds.
Verify: Run Your First Node Script
Version numbers prove the install; a running script proves the toolchain. In a PowerShell window (the Set-Content line is PowerShell-specific), in any folder:
Set-Content hello.js 'console.log("Node on Windows says hello via DevAnswers")'
node hello.js
Node on Windows says hello via DevAnswers
And the npm half, creating a project and pulling in one package:
npm init -y
npm install cowsay
If a node_modules folder and a package-lock.json appear, npm is downloading and installing packages correctly, and every Node tutorial on the internet is now open to you.
Troubleshooting
- ‘node’ is not recognized as an internal or external command. Nine times out of ten you are in the same terminal you installed from: the installer updated the PATH, but open windows keep their old environment, so open a new terminal (or sign out and in). If a fresh window still fails, confirm
node.exeexists inC:\Program Files\nodejs, and that this folder is in your PATH (Settings › System › About › Advanced system settings › Environment Variables). Add it if missing, then open another new terminal. - npm.ps1 cannot be loaded because running scripts is disabled on this system. PowerShell’s execution policy, a safety feature controlling which scripts load, is blocking npm’s PowerShell wrapper. The standard fix allows locally-created scripts for your user only:
Set-ExecutionPolicy RemoteSigned -Scope CurrentUser
Answer Y, open a new PowerShell window, and npm works. RemoteSigned still requires downloaded scripts to be signed, so it is the sensible middle ground rather than an off switch. If you cannot change policy (a locked-down work machine), npm.cmd bypasses the PowerShell wrapper, and plain Command Prompt is unaffected.
Next Steps
Node and npm are installed, verified with a real script, and the two classic Windows traps are behind you.
- Keep npm itself current with
npm install -g npm@latestevery few months. - When a second project needs a different Node, that is your cue to switch to nvm-windows (Method 3).
- Working with PHP on Windows too? Our guide to installing Composer and PHP on Windows completes the toolchain.
Comments