Skip to content

Instantly share code, notes, and snippets.

@willbreitkreutz
Last active March 15, 2019 19:01
Show Gist options
  • Save willbreitkreutz/11c9cb80001e0d2b3de07e2b68b50a79 to your computer and use it in GitHub Desktop.
Save willbreitkreutz/11c9cb80001e0d2b3de07e2b68b50a79 to your computer and use it in GitHub Desktop.

To get Node.js and NPM running on Windows without admin rights.

These are the steps that worked for me, no guarantees for anyone else... That said, this should work for most cases.

Node.js - We want version v10.15.3 (as of 3/15/2019)

  1. Go to the Node.js downloads page
  2. Click on Other Downloads, DO NOT DOWNLOAD THE INSTALLER. Download the binary zip for your operating system, for Windows grab the Windows Binary matching your 32 or 64 bit system.
  3. Extract the zip file to an easy place to remember on your system, I use C:\Node
  4. Open the "Edit Environment Variables for Your Account" tool by searching for the term "env" in the search bar next to your start button.
  5. You should see a variable named "Path" in the list, if not, you can add it by clicking New, otherwise, click the Path variable and then click Edit
  6. Add the path to the folder where you saved the node.exe file, make sure to use semi-colons to separate elements in the variable. In my case I added it to the end of the Path variable like so: ...\bin;C:\Node; (this will cover us for NPM as well)
  7. Click OK to exit the envrionment variable editor.

## NPM - We want the 4.x branch (as of 5/24/2017)

Edit - The Node.js zip download now includes a version of NPM, use these instructions to have more control over the version of npm that you are running, but you might will be ok just using the one included with Node.

  1. Go to the NPM github releases page at https://github.com/npm/npm/releases
  2. Download the latest full release, you want the Source Code (zip) option, you will see many pre-releases, ignore these unless you know what you're doing, the Latest Release will be marked with a green tag.
  3. Go to the location where you saved the node.exe file.
  4. Create a folder called node_modules next to thenode.exe file, mine is C:\Node\node_modules
  5. Extract the npm zip file into the new node_modules folder
  6. Remove the version number from the folder that gets placed into the node_modules folder, mine went from C:\Node\node_modules\npm-4.5.0 to C:\Node\node_modules\npm
  7. Copy npm.cmd from ...\npm\bin to the folder with node.exe in my case I copied to C:\Node

Testing

  1. Open command propt
  2. Type > node --version and you should see something like v10.15.3
  3. Type > npm --version and you should see something like v6.4.1

Updating

You can update node by downloading the latest executable from the URL above and replacing node.exe. NPM can be updated by following the steps above, or by running > npm install npm -g from command prompt, this is usually easier.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment