Cross-platform Node.js version management for PowerShell users
A pure PowerShell module for managing multiple Node.js versions across Windows, Linux, and macOS without leaving your preferred shell.
- nvm: Bash-only, doesn't work in PowerShell
- nvm-windows: Windows-only, often requires admin rights
- fnm: Fast but requires Rust toolchain
- Manual management: Error-prone PATH and environment variable juggling
This PowerShell module provides a simple interface for managing Node.js versions, using a clean set of commands:
| Command | Purpose |
|---|---|
Get-NodeVersion |
Lists versions (-Available, -Installed, -Current) with filtering |
Set-NodeVersion |
Internal logic to set environment vars (not for end user use) |
Switch-NodeVersion |
Public-facing command to switch to a specific Node version |
Install-NodeVersion |
Installs a new Node version |
# Show all installed versions
Get-NodeVersion -Installed
# Show all available versions that match 24.*
Get-NodeVersion -Available -Versions 24.*
Get-NodeVersion -Available -v 24.*
Get-NodeVersion -Available -like 24.*
# Show currently used Node versions on machine and process level
Get-NodeVersion -Current
# Switch to version 18.16.0
Switch-NodeVersion 18.16.0
# Install a new version
Install-NodeVersion 20.11.1git clone https://github.com/Kylar514/ps-nvm.git- run this command in pwsh
Import-Module ./ps-nvm/core.psm1
- Add this to your powershell profile
Import-Module "$HOME/Path/To/ps-nvm/core.psm1"
- pwsh core 7+
- nvm for the directories and env vars