Download and install pyWin32 (64-bit or 32-bit) and put a.Pie into PyInstaller. Run CMD, go to the PyInstaller directory and type Python PyInstaller. py a.py and then go to C:\Python27\Lib\site-packages\selenium-2.47.1-py2.7.egg on disk C The entire Selenium folder is copied to PyInstaller/A /dist/ A /. Then run dist/a/a.exe to compress the big folder a and you’re done!