Python has a huge number of GUI frameworks (or toolkits) available for it, from TkInter (traditionally bundled with Python, using Tk) to a number of other cross-platform solutions, as well as bindings to platform-specific (also known as 'native') technologies.
Cross-Browser Frameworks
The Python for macOS installers downloaded from this website dynamically link at runtime to Tcl/Tk macOS frameworks. The Tcl/Tk major version is determined when the installer is created and cannot be overridden. All current python.org installers for Python 3.7.x, 3.6.x, and 2.7.x link to their own built-in Tcl/Tk 8.6 frameworks and do not use external Tcl/Tk frameworks so the rest of this. WxWidgets (the Python flavor is called wxPython) is currently your best option IMHO, they have support for multi platform (Mac, Window, Linux) and the framework is pretty easy to work with. WxWidgets lets developers create applications for Win32, Mac OS X, GTK+, X11, Motif, WinCE, and more using one codebase. Try it with Tkinter instead of tkinter - if that works, your IDE is somehow configured to use Python 2 instead of 3. – jasonharper May 8 '19 at 12:24 @jasonharper - Thank you very much for your reply. As an answer for #1: Yes. It is quite good for this; scripting languages with GUI toolkits are often a good way to put a GUI on an application. They can also be used to wrap applications written in low level languages such as C or C. Python offers good integration to quite a few toolkits.
Package | Target | Latest version | Latest update date | Notes |
All major Web Browsers | 0.12 | 2020-08-28 | For versatile GUIs written in HTML/CSS and Python (no JavaScript needed) - The lightweight and easy-to-use toolkit to begin with GUI programming. | |
All major Web Browsers | 0.8 | 2012-06-01 | Comprehensive Widget toolkit, Python-to-Javascript compiler and AJAX library. Provides the 'V' in MVC. Note PyjamasDesktop was merged into pyjamas. |
Idle Python Mac
Cross-Platform Frameworks
The major cross-platform technologies upon which Python frameworks are based include Gtk, Qt, Tk and wxWidgets, although many other technologies provide actively maintained Python bindings.
Package | Target | Latest version | Latest update | Notes |
Windows, MacOS, Linux | 0.94 | 2019-05-26 | Simple & intuitive wrapper for Tkinter. In active development, designed for educational purposes, heavily documented & feature rich! | |
Linux / many | 0.11.0 | 2016-02-16 | Fully automatic, live connection among graphical interface widgets and application variables. | |
Windows, MacOS, Linux | 66.0 | 2018-08-20 | Python bindings for the CEF Framework. CEF is based on Google Chromium and focuses on facilitating embedded browser use cases in third-party applications. With CEF you can create a light-weight native “shell” application that hosts a user interface developed primarily using Web technologies. Examples of embedding CEF browser control are available for many popular GUI toolkits such as PyQt, PySide, wxPython, PyGTK, PyGObject, Kivy and PyGame/PyOpenGL. | |
0.9.16 | 2016-08-16 | Dabo is a 3-tier, cross-platform application development framework, written in Python atop the wxPython GUI toolkit | ||
Windows, MacOS, Linux | 0.4.605 | 2020-10-12 | DearPyGui A GPU Accelerated Python GUI Framework. At its' core it is a Python implementation of DearImGui. Docs are located on the Github Pages. | |
Qt | 1.1.0 | 2015-11-15 | A tiny Python module for creating form dialogs/widgets to edit various type of parameters with having to write any GUI code | |
WxPython (WxWidgets) | 0.9.3 | 2013-08-26 | Both a framework and visual tools: GUI Designer, Inspector and Property Editor. Supports Python 2.5 to Python 3.2; wxPython 2.8 'stable', 2.9 'classic' and 'phoenix' (py3k). Features advanced pythonic MVC controls (ListView, GridView, TreeView) using list- and dict-like objects; masked and date picker controls; common dialogs; fluid layout using sizers & basic HTML; simplified event model (similar to JavaScript). Can include wxPython code in apps. Modern PythonCard 'fork' hugely enhanced. | |
Qt | 1.7.6 | 2016-10-09 | Based on the Qt Python binding module PyQt4, guidata is a Python library generating graphical user interfaces for easy dataset editing and display. It also provides helpers and application development tools for PyQt4. | |
Qt | 0.3.5 | 2020-07-10 | A Qt wrapper that makes it extremely easy to create simple graphical interfaces | |
wxPython | 1.0.3 | 2019-09-22 | Converts most argparse based CLI programs into wxPythonGUI programs with a single import and decorator. | |
Windows, MacOS, Linux (Tkinter based) | 1.1.0 | 2019-10-24 | The aim of guizero is to make the process of creating simple GUIs quick, accessible and understandable for children. It is a Python 3 library based on Tkinter, for creating simple GUIs. | |
.NET/Mono | 2.7.4 | 2013-09-07 | Python for (originally MS') .NET platform. See IronPython for more info. | |
Java | 2.7.1 | 2017-06-30 | Jython is an implementation of the high-level, dynamic, object-oriented language Python seamlessly integrated with the Java platform. See Jython | |
Windows, MacOSX, Linux, Android, iOS | 1.11.0 | 2019-06-01 | OpenGL ES accelerated framework for creating new user interfaces. Kivy have a native multitouch support for every platform, mouse simulator, widgets multitouch ready, integrated virtual keyboard, rst renderer... | |
Windows, MacOS, Linux | 1.8.2 | 2014-07-16 | Not strictly a GUI toolkit, but a high-level multimedia framework that allows construction of media-rich guis. | |
1.3.1 | 2012-02-19 | supports Windows/Unix/Mac and provides access to OpenGL features. Stands for Fast, Light Toolkit.(Python 2 & 3) | ||
Qt & OpenGL | 2016-12-20 | A Python framework to develop GUI application, which promotes modular software design and code reusability with minimal effort. | ||
1.9.6 | 2019-04-25 | Primarily an introduction to game programming. Only supports one window.(Python 2 & 3) | ||
Windows, MacOS, Linux | 1.4.8 | 2019-11-21 | Cross-platform windowing and multimedia library that heavily uses OpenGL. | |
Gtk? | 3.34.0 | 2019-09-12 | PyGObject (aka PyGI). Python Bindings for GLib/GObject/GIO/GTK+. Replacement for PyGtk. See PyGobject | |
Gtk | 2.24.0 | 2011-04-01 | See PyGtk. Bindings for pango, atk, gtk and libglade. Good documentation from the Gtk Project. Wrapper uses some C programming style Note: New users are encouraged to use GTK+3 through the PyGObject bindings instead of using PyGTK with GTK+2. Windows users may still want to keep using PyGTK until more convenient installers are published. | |
GObject Introspection | 0.1.1 | 2011-03-29 | Pure Python GObject Introspection Repository (GIR) wrapper using ctypes. Supported CPython >= 2.6, CPython 3.x, PyPy >= 1.4.0, and on all platforms where gobject introspection is supported. | |
Cocoa / Gtk / Win32 | 2.5.3 | 2011-07-16 | Abstract, pythonic API encapsulating different platforms. | |
Qt | 5.15.1 | 2020-09-12 | Python bindings for the Qt application development framework (Python 2 & 3) | |
Sciter | 4.3.0.6 | 2016-02-16 | Python bindings for the Sciter - embeddable HTML/CSS UI engine. Windows, MacOS, Linux and mobiles. | |
Qt | 5.15.0 | 2020-06-15 | The Qt for Python (PySide) project provides licensed Python bindings for the Qt cross-platform application and UI framework. | |
tkinter, Qt, wxPython,Browser, Win, Mac, Linux, Pi, PyDroid3, Trinket | 4.20.0 | 2020--06-06 | Wraps tkinter, Qt (pyside2), wxPython and Remi (for browser support) in a non-OOP API. Build custom GUI layouts in a few minutes in a few lines of code. Easy enough for beginners, powerful enough for advanced users. Extensive documentation. 100+ Built-in color themes. Runs online using Trinket. 200 example programs. | |
Cocoa / Win32 / Qt / GTK | 0.8.2 | 2015-10-08 | Pywebview is a lightweight cross-platform native wrapper around a webview component that allows to display HTML content in its own dedicated window. | |
OLPC XO with Linux | 0.98.5 | 2013-03-08 | User interface for collaborative educational software | |
OSX, GTK+, iOS | 0.2.4 | 2016-10-13 | Cross platform, Python native GUI toolkit that uses native system widgets. Under development as part of the BeeWare project. (Latest releases) | |
Tk | Included in Python standard library | Python's 'standard' GUI library (Documentation) | ||
Qt or Wx on Windows, MacOS, Linux | 6.0.0 | 2018-04-03 | The Traits/TraitsUI package offers the ability to build scalable and cross-platforms GUIs simply by focusing on the model being viewed, and offering default widgets for various types of objects. It abstracts away the implementation, which can currently use PyQt, Pyside or WxPython. In the simplest case, it can automatically generate a user interface for editing a (Traits-based) object, with no additional coding on the part of the programmer-user. In more sophisticated uses, it can implement a Model-View-Controller (MVC) design pattern for Traits-based objects. | |
many | 6.1.0 | 2014-01-22 | The Visualization ToolKit (VTK) is an open source, freely available software system for 3D computer graphics, image processing, and visualization. | |
4.0.4 | 2019-01-05 | Supports Windows/Unix/Mac. See wxPython. Supports Python 2.7 and >=3.4, pip installable. Wraps & extends the wxWidgets toolchain. Permissive Licence. |
Platform-specific Frameworks
Package | Target | Latest version | Latest update | Notes |
8.0.1 | 2020-07-28 | A plugin for Android Studio's Gradle-based build system. Supports embedding Python code within a regular Java/Kotlin app, or writing an app entirely in Python with full access to the Android API. | ||
MacOSX | 6.2.2 | 2020-07-08 | Supports Cocoa Aqua GUIs on the Mac | |
MorphOS | 0.7.0 | 2013-12-27 | LGPL MagicUserInterface wrapper for Python. Support for MorphOS 2.x.(Python 2.7) | |
Windows | 228 | 2020-06-13 | Previously called win32all. Also known by the names of its components: PythonWin (for the UI), Win32Com (for COM/ActiveX), Win32 (for some other parts of the API) |
GUI Design Tools and IDEs
IDE | Target | Latest version | Latest update date | Notes |
5.4.2 | 2014-03-09 | GPL. a full featured Python and Ruby editor and IDE, integrating the highly flexible Scintilla editor control.(Python 2 & 3 versions) | ||
0.9.6.1 | 2016-09-05 | Visual GUI Designer, Inspector and Property Editor (embeddable). PythonCard 'fork'. LGPL3. | ||
3.16.1 | 2013-12-18 | GPL. Glade is a RAD tool to enable quick & easy development of user interfaces for the GTK+ toolkit and the GNOME desktop environment. | ||
12.0.1 | 2020-02-10 | Commercial | ||
MacOSX, Win, Linux | 3.0.38 | 2014-01-24 | App to creating 2D visuals using Python programming code. | |
TkInter, Tix | 4.2.1 | 2014-02-21 | GUI editor for Windows, Mac and Linux. | |
0.10.3 | 2020-10-03 | GPL TkInter GUI builder (exports XML '.ui' files) and RAD tool inspired by Glade. | ||
Windows | 2.5.1 | 2012-03-19 | MIT Open Source IDE developed using Python and Delphi. See PyScripter.(Python 2 & 3) | |
Windows/Linux/Mac | 13.01 | 2013-03-07 | An interactive environment for python, suitable for interactive GUI programming with different GUI toolkits (wxPython, TkInter, pyGTK, pyQT4 and PySide) | |
3.9.0 | 2018-10-26 | GPL cross-platform WYSIWYG GUI builder. Can produce XRC/XML, wxWidgets/C++, or wxPython/python. | ||
0.9.2 | 2019-03-07 | MIT License, wxGlade is a GUI designer written in Python with the popular GUI toolkit wxPython, that helps you create wxWidgets/wxPython user interfaces.. See WxGlade supports Python 2.7 & >=3.4 + wxPython >=2.8 or >=4.0 |
Links
http://en.wikipedia.org/wiki/Comparison_of_integrated_development_environments#Python - Wikipedia article describing several IDE's and GUI Builders.
Editorial Notes
The above lists should be arranged in ascending alphabetical order - please respect this when adding new frameworks or tools.
CategoryPyGUI
The Python programming language works on many platforms including Microsoft Windows, Apple Mac OS X, many Linux distributions other systems.
This article consists of two parts:
- GUI module - how to create a desktop interface with Python
- Python to Executable - turn a Python program into an executable
The hardest part is learn Python, how to use a GUI module. To create an executable, there are several command line tools.
GUI module
The first thing you will need is a GUI module. Of course, there are many GUI modules for Python. The most commonly used GUI modules are:
- Tkinter - this module is based on the old Tk GUI toolkit. It is the default GUI library for python and it is free for commercial projects. Tk is rather limited with the number of widgets and has an old design.
- PyQt - Python bindings for the Qt framework. It's free (gpl) but not for commercial products. Qt comes with many widgets and features and is under continuous development. If you are new to PyQt, I recommend this course & book.
- PyGTK, a wrapper on the GTK toolkit. The gnome (gtk) desktop environment is an option on Linux systems.
Python is interpreted
Strictly speaking, you don't have to compile python for Mac/Windows/Linux because it is an interpreted language.
That means that if you have the Python interpreter installed on the platform and the required modules, you can run the program.
Python is installed on every Linux, Mac and Windows OS (I think) by default now. So all you need is have the non-standard modules installed if you use them.
However, your end-users may not be familiar with Python and other installing modules, so you may want to create an executable and an installer.
It is possible to build executables with the python interpreter, which we will discuss in the next section.
Create executable
After you made your GUI program in Python, you can convert it into a standalone executable. There are several tools that can do this, there is more than one way to do this.
Cross platform, all platforms
- PyInstaller - PyInstaller freezes Python apps into stand-alone executables for Windows, Linux, Mac OS X, FreeBSD, Solaris and AIX. It supports Python 2.7 and Python 3.3, 3.4, 3.5 and 3.6.
First install it with the pip package manager:
Then run pyinstaller in your programs folder:
- fbs - package Python apps that use PyQt. See Python PyQt to executable. fbs is not free for commercial use, but for non-commercial use it's free. It comes with setup program for your end-users.
Windows executable
- py2exe - converts your Python program to a windows executable. It's only for building executables on Windows, you can't build a Windows executable from Linux or Mac OS X.
Linux executable
Best Gui For Python Machine Learning
- Freeze - works like py2exe but for the Linux platform
Mac executable
Gui Programming Python Mac
- py2app - create Mac OS executables from Python. py2app is similar in purpose and design to py2exe for Windows.