WinPython - Python for Microsoft Windows

If you wish to run Python on a Microsoft Windows system, you can use WinPython. The first window you will see when run run the downloaded installation file is one for the license agreement, which notes "WinPython components are distributed as they were received from their copyright holder, under their own copyright and/or license, and without any linking with each other." WinPython itself uses the MIT license.

Mastering Python
Mastering Python
1x1 px




Python by Example
Python by Example
1x1 px

WinPython License Agreement

Once you accede to the license, you will be prompted for a destination folder. By default that will be a WinPython directory created beneath the directory where you're running the downloaded file from, but you can change the location.

WinPython select installation diectory

When the installation has been completed, a window will appear where you can click on a Finish button to exit from the installation program.

Data Visualisation with Plotly and Python
Data Visualisation with Plotly and Python
1x1 px

WinPython installed

The following output from the dir command shows the files and directories installed for WinPython 32 3.5.5.2Zero.

C:\Users\Pamela>dir "C:\Program Files (x86)\WinPython"
 Volume in drive C is OS
 Volume Serial Number is 4445-F6ED

 Directory of C:\Program Files (x86)\WinPython

05/12/2018  09:23 PM    <DIR>          .
05/12/2018  09:23 PM    <DIR>          ..
04/05/2018  01:07 PM            60,439 IDLEX (Python GUI).exe
04/05/2018  01:07 PM           142,368 IPython Qt Console.exe
04/05/2018  01:07 PM            75,292 Jupyter Lab.exe
04/05/2018  01:07 PM            75,297 Jupyter Notebook.exe
05/12/2018  09:23 PM    <DIR>          notebooks
05/12/2018  09:23 PM    <DIR>          python-3.5.4
04/05/2018  01:07 PM           144,412 Qt Designer.exe
05/12/2018  09:23 PM    <DIR>          scripts
05/12/2018  09:23 PM    <DIR>          settings
04/05/2018  01:07 PM           140,320 Spyder reset.exe
04/05/2018  01:07 PM           141,337 Spyder.exe
05/12/2018  09:23 PM    <DIR>          t
04/05/2018  01:07 PM            73,241 WinPython Command Prompt.exe
04/05/2018  01:07 PM           129,047 WinPython Control Panel.exe
04/05/2018  01:07 PM            60,443 WinPython Interpreter.exe
04/05/2018  01:07 PM           121,883 WinPython Powershell Prompt.exe
              11 File(s)      1,164,079 bytes
               7 Dir(s)  848,407,552,000 bytes free

C:\Users\Pamela>

You can get a Python command prompt, such as you would have with a command-line interface (CLI) to Python on a Linux or OS X system by double-clicking on the WinPython Command Prompt application in the File Explorer.

Aiseesoft Video Converter Ultimate

WinPython directory

You will then see a prompt like the one below where you can start Python by typing python and hitting Enter. You will then see Python's >>> prompt where you can enter commands.

C:\Program Files (x86)\WinPython\scripts>python
Python 3.5.4 (v3.5.4:3f56838, Aug  8 2017, 02:07:06) [MSC v.1900 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> 3 + 2
5
>>>

You can exit from Python by typing exit(). If you want to run a Python script, you can run them from that command prompt interface by typing python scriptname where scriptname is the name of the script. E.g., I could use Notepad to create a simple "Hello, world" script by putting just print ("Hello, world!") in a file and then saving it as helloworld.py by selecting "All Files" for the Save as type value rather than the default value of "Text Documents (*.txt)". When I want to run the program I can use a command like the one below:

C:\Program Files (x86)\WinPython\scripts>python c:\temp\helloworld.py
Hello, world!

C:\Program Files (x86)\WinPython\scripts>

You can obtain another command line interface for running scripts by double-clicking on WinPython Powershell Prompt, which will run Python from a Powershell prompt.

Alternatively, you can run Python scripts using the IDLEX (Python GUI) program you will see in the installation directory.

Python 3.5.4 (v3.5.4:3f56838, Aug  8 2017, 02:07:06) [MSC v.1900 32 bit (Intel)] on win32
Type "copyright", "credits" or "license()" for more information.
>>>

If I had already written the "Hello, world!" script, I could run it by clicking on File then selecting Open and browsing to the location of the script. The script will open in another window where I can click on Run and then Run module to execute the script (or you can just hit the F5 key to run the script.

Python hello world script

The output will appear in the first window.

Python hello world output