How to install wxPython inside a virtualenv environment

python-pip does not contain wxPython module. So, to use it inside an virtualenv environment (e.g.: /home/.venv/myenv/):


1. Install it system-wide:

$ sudo apt-get install python-wxgtk2.8


2. Make a symbolic link of wxPython to the virtualenv:

$ ln -s /usr/lib/python2.7/site-packages/wx* /home/.venv/myenv/lib/python2.7/site-packages/



Update: In xUbuntu 12.04:

$ ln -s /usr/lib/python2.7/dist-packages/wx* /home/.venv/myenv/lib/python2.7/site-packages/

Comments