Update: If you’re already using Python >=3.3 then there’s is already a package called venv which you can use to create you’re virtual environment with just:

python3 -m venv myennv

virtualenv is very useful in developing Python because you can create your project’s own environment without polluting the or messing with the global or your other projects Python environment.

First make sure that you have already installed virtualenv and pip for Python 3.

$ sudo apt-get install python3-pip 
$ sudo pip3 install virtualenv

Continue reading