PyGObject
Python bindings for GObject Introspection
What it is and what it does
PyGObject is a bridge between Python and the GObject type system, which underlies most GNOME libraries and many other C-based projects. It uses GObject Introspection to automatically generate Python bindings for libraries written in C, allowing developers to call GObject-based APIs directly from Python code. The package supports Python 3.10+ and PyPy3, and works across Linux, Windows, and macOS.
Typically used to build desktop applications with GTK, multimedia applications with GStreamer, or web applications with WebKitGTK. Because it wraps compiled C libraries, installation requires a working C compiler and the development headers for the underlying libraries you want to use. The bindings are generated dynamically at runtime via introspection metadata, so you gain access to new library versions without waiting for manual binding updates.
Use it for:
- Build GTK-based desktop applications with native look and feel on Linux, Windows, and macOS.
- Create multimedia applications using GStreamer for audio and video playback.
- Develop web-based applications using WebKitGTK as an embedded browser engine.
- Access system services and file I/O through GLib and GIO from Python.
- Integrate Python scripts with GNOME desktop environment components.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
PyGObject provides Python bindings for GObject-based libraries such as GTK, GStreamer, WebKitGTK, GLib, and GIO, enabling Python developers to build graphical and multimedia applications.
Yes, if you need to build desktop or multimedia applications using GObject-based libraries. The high install friction (requires C compiler and system headers) and copyleft license are the main trade-offs. The package is actively maintained, has no known vulnerabilities, and is the standard way to access GTK and GStreamer from Python. Not suitable if you cannot meet the compilation requirements or need a permissive license for proprietary redistribution.
Install
pygobject on PyPI
pip
pip install pygobjectuv
uv add pygobjectpoetry
poetry add pygobjectInstalling PyGObject
Before you install
Installation requires a C compiler and system development headers; the package is distributed only as source. Maintenance is active with a recent release within the last 98 days.
License in practice
Licensed under LGPLv2.1+, a copyleft license permitting use in both free and proprietary software provided you distribute source code and allow relinking. Derivative works must be licensed under the same terms.
Quickstart
pip install PyGObject
Then import and use bindings for GObject-based libraries via introspection metadata at runtime.
Requires a C compiler, system development headers, and underlying GObject libraries (GTK, GLib, etc.) installed on the host system.
Verify before relying
- Whether pre-built wheels are available for common platforms to avoid compilation.
- Performance characteristics when wrapping large GObject hierarchies or frequent callback invocations.
- Compatibility details with specific GTK versions and other GObject library versions.
- Specific usage patterns and code examples for common GObject-based libraries.
Package facts
| License | GNU LESSER GENERAL PUBLIC LICENSE Version 2.1, February 1999 Copyright (C) 1991, 1999 Free Software Foundation, Inc. 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Everyone is permitted… (full text in the JSON record) (copyleft) |
| Python support | supports the current Python release (>=3.10) |
| Install friction | high — source build required |
| Runtime dependencies | 1 — pycairo |
| Maintenance | actively maintained — 98 days since the last release |
| First released | |
| Downloads | 630,220/month — #5,664 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: pygobject-3.56.3.tar.gz
Tags
More Python Modules packages
Converts domain names between Unicode and…
permissive · top 100 on PyPI
setuptoolsSetuptools is a Python build backend and…
permissive · top 100 on PyPI
PyYAMLPyYAML parses and emits YAML 1.1 data format,…
permissive · top 100 on PyPI
pydanticPydantic validates Python data structures…
permissive · top 100 on PyPI
annotated-typesProvides reusable metadata objects for use with…
permissive · top 100 on PyPI
typing-inspectionProvides runtime tools to inspect and…
permissive · top 100 on PyPI
dbus-pythonProvides Python bindings to libdbus, allowing…
permissive · top 15,000 on PyPI
pywebviewpywebview wraps native webview components to…
permissive · top 5,000 on PyPI
imguiPython bindings for the dear imgui C++ library,…
permissive · top 15,000 on PyPI
notify2notify2 creates and displays desktop…
permissive · top 15,000 on PyPI
wxPythonwxPython provides Python bindings to the…
unclear · top 15,000 on PyPI
PyQt5PyQt5 provides Python bindings for the Qt v5…
copyleft · top 5,000 on PyPI
audioreadDecode audio files using whichever backend is…
permissive · top 5,000 on PyPI
dbus-nextA pure-Python DBus library for Linux desktop…
permissive · top 15,000 on PyPI
shiboken2Shiboken2 provides Python access to metadata…
copyleft · top 15,000 on PyPI