How to download and install Node.js on Mac
Node.js is a free JavaScript runtime, and its official installer for Mac comes from nodejs.org with npm included. Here is which version to pick, how to install it and what to check afterwards.

Node.js
- macOS 13.5 or later
- One installer for Apple Silicon and Intel
- Free, open source
Or the installer straight from the developer’s server:
The links go to the developer’s website (nodejs.org). MacWashing is not affiliated with the developer and keeps no installers.
Open Terminal (Applications › Utilities) and run:
brew install nodeHomebrew downloads the app from the developer’s server, checks the file and puts the app in Applications.
No Homebrew yet? How to install Homebrew: one command from brew.sh.
nvm (Node Version Manager) installs Node.js into your home folder and switches between versions per project. Install it with the command from its official repository:
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.8/install.sh | bashQuit and reopen Terminal, then install the LTS version and check it:
nvm install --ltsnode -vIf Terminal says nvm: command not found, create the shell’s settings file: touch ~/.zshrc Then run the install command again and reopen Terminal. Don’t mix nvm with the .pkg installer or Homebrew’s Node: pick one.
Which version to download
nodejs.org offers two lines of Node.js:
- LTS (long-term support): supported for years and the one most projects and tutorials expect. Pick it if you’re not sure.
- Current: the newest features. A new major version comes out every six months, and each even-numbered one becomes LTS in October.
The macOS installer is one .pkg for Apple Silicon and Intel Macs and needs macOS 13.5 or later. Download it only from nodejs.org. The direct link in the card is the Current installer: LTS has no permanent link, so take it from the download page.
How to install Node.js
- On the download page, choose the version and macOS, then download the installer (
.pkg).

- Open the downloaded
node-….pkgin your Downloads folder and click Continue. - Click Continue and Agree to accept the license, then Install, and enter your Mac password.
- When the installer says Node.js and npm were installed in
/usr/local/bin, click Close.
What to set up after installing
Open a new Terminal window and check both commands:
node -vnpm -v- npm comes with Node.js. No separate install is needed, and
npxis there too. - Global packages. With the
.pkg, global installs with npm’s-gflag write to a system folder and may fail with an EACCES error. Instead ofsudo, npm’s documentation suggests a Node.js version manager or another folder for global packages. - npm cache. npm keeps downloaded packages in
~/.npm, and the folder grows with every project. - The installer. Move the
.pkgfrom Downloads to the Trash once the version check works.
If Node.js won’t install or run
- «command not found: node». Open a new Terminal window. If it still fails, check that this lists
/usr/local/bin:echo $PATH - The installer refuses to install. Check your macOS version in About This Mac: current Node.js needs macOS 13.5 or later.
- Two copies of Node.js get in each other’s way. If you installed Node.js both from the
.pkgand with Homebrew, this shows which one runs:which nodeKeep one of them.
Alternatives to Node.js
Keep your Mac tidy

npm and other developer tools keep caches that grow with every project. System Junk in MacWashing finds the caches apps and developer tools build up and shows how much space they take.
Free trial · macOS 14 or later
Questions and answers
Is Node.js free?
Yes. Node.js and npm are free and open source.
Should I use the installer or Homebrew?
The installer from nodejs.org is the official way. Homebrew installs the newest Node.js and updates it with its usual command: brew upgrade For an LTS line it has versioned formulas such as node@24.
Do I need to install npm separately?
No. npm is installed together with Node.js, by the .pkg and by Homebrew alike.