protractor Getting started with protractor Installing and Setting up Protractor (On Windows)


Requirements: Protractor requires the following dependencies to be installed prior to installation:

  • Java JDK 1.7 or higher
  • Node.js v4 or higher


Download and install Node.js from this URL:

To see if the Node.js installation is successfull, you can go and check the Environment variables. The 'Path' under System Variables will be automatically updated.

Path variable to check Node.js installation

You can also check the same by typing the command npm -version in command prompt which will give you the installed version.

command to check Node.js installation

Now Protractor can be installed in two ways: Locally or Globally.

We can install protractor in a specified folder or project directory location. If we install in a project directory, every time we run, we should run from that location only.

To install locally in project directory, navigate to the project folder and type the command

npm install protractor

To install Protractor globally run the command:

$ npm install -g protractor

This will install two command line tools, protractor and webdriver-manager.
Run protractor --version to ensure protractor was successfully installed.

webdriver-manager is used to download the browser driver binaries and start the selenium server.
Download the browser driver binaries with:

$ webdriver-manager update

Start the selenium server with:

$ webdriver-manager start

To download internet explorer driver, run the command webdriver-manager update --ie in command prompt. This will download IEDriverServer.exe in your selenium folder