How can I install Node.js LTS using a Node Version Manager (NVM)?

Responsive Ad Header

Question

Grade: Education Subject: Support
How can I install Node.js LTS using a Node Version Manager (NVM)?
Asked by:
65 Viewed 65 Answers

Answer (65)

Best Answer
(267)
Install NVM: `curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.7/install.sh | bash`. Then, source the NVM script: `source ~/.bashrc` or `source ~/.zshrc`. Finally, install the LTS version: `nvm install --lts`. To use the LTS version, run `nvm use --lts`.