Install OpenCV: ~10 min!


  1. Tested on: Windows 7, Windows 10
  2. There could be other ways to get Open CV working on your Windows computer

Before installation

  1. Find you OS architecture
  2. Decide the Python version (e.g. 2.7 or 3.x)
  3. Install Anaconda, open terminal as administrator and , launch “python” and type “import numpy as np”, to test your installation
  4. Decide the version of Open CV you want to install, from the list of available versions
  5. Upgrade pip (use pip3 if using Python 3.x)

Find your OS architecture by issuing following command:

systeminfo | findstr /I type:

Install or Upgrade pip (or pip3 for Python 3.x):

python -m pip install --upgrade pip


You can install Open CV using pip or manually. Installing Anaconda should already have taken care of dependencies for Open CV.

To find the list of available versions of Open CV through pip (or pip3) I use following:

pip install opencv_python==

Which prints an informative error message as following

Collecting opencv_python==
Could not find a version that satisfies the requirement opencv_python== (from versions:,,,,,,,,,,
No matching distribution found for opencv_python==

If your version is in the list …

pip install 'opencv_python==x.x.x.x...'

… and done! Skip ahead to verification.

else If you want to install using (Ana)conda …

In Anaconda command prompt

conda install -c menpo opencv

// alternatives:

source: Anaconda, Stackoverflow


But if you need to install a version(e.g. 2.4.9) that is not available through pip, you need to download that version, extract the files.

  • Let’s say you extracted your files to C:\opencv folder, on a 64 bit operating Windows OS and you are using Python 2.7. Navigate to C:\opencv\build\python\2.7\x86
  • Copy cv2.pyd file
  • Navigate to Anaconda Python installation path, in my case C:\Users\WildClick\AppData\Local\Continuum\Anaconda2\Lib\site-packages



Start Python in Anaconda terminal, type

import cv2

Related articles

  1. MSDN
  2. Read The Docs

Leave a Comment

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s