Install Node.js on Windows
Essential Runtime Environments for the Three Major AI Coding Tools
💡 Important note
Claude Code, CodeX, and Gemini CLI all require a Node.js 18+ runtime environment. If you have already installed Node.js 18 or later, you can skip this section. Verification command: node -v
Method 1: Official Installer (Recommended)
- Visit the official Node.js website: https://nodejs.org/zh-cn/download
- Download the LTS (Long-Term Support) version of the Windows Installer (.msi)
- Run the installer package and complete the installation using the default settings
- The installer will automatically configure the system
PATHenvironment variable
Method 2: Install via Package Manager
Using Winget
Windows 11 or the latest version of Windows 10:
powershell
winget install OpenJS.NodeJS.LTSUsing Chocolatey
You must install Chocolatey first:
powershell
choco install nodejs-ltsUsing Scoop
powershell
scoop install nodejs-ltsVerify installation
Open Command Prompt or PowerShell, then run:
powershell
node --version
npm --versionIf a version number is displayed (such as v18.x.x or later), the installation was successful.
Frequently Asked Questions
Prompt: "is not recognized as an internal or external command"
- Reopen the terminal window
- Check whether the PATH environment variable includes the Node.js path
- Restart your computer and try again
Installation Failed
- Run the installer as an administrator
- Disable your antivirus software and try again
- Check whether the system drive has enough free space
Next steps
✅ Environment setup is complete!
You can now continue installing Claude Code, CodeX, or Gemini CLI.