cibuildwheel

Python wheels are great. Building them across Mac, Linux, Windows, on multiple versions of Python, is not.

cibuildwheel is here to help. cibuildwheel runs on your CI server - currently it supports GitHub Actions, Azure Pipelines, Travis CI, AppVeyor, CircleCI, and GitLab CI - and it builds and tests your wheels across all of your platforms.

What does it do?

macOS Intel macOS Apple Silicon Windows 64bit Windows 32bit Windows Arm64 manylinux
musllinux x86_64
manylinux
musllinux i686
manylinux
musllinux aarch64
manylinux
musllinux ppc64le
manylinux
musllinux s390x
musllinux armv7l Pyodide
CPythonΒ 3.6 βœ… N/A βœ… βœ… N/A βœ… βœ… βœ… βœ… βœ… βœ… N/A
CPythonΒ 3.7 βœ… N/A βœ… βœ… N/A βœ… βœ… βœ… βœ… βœ… βœ… N/A
CPythonΒ 3.8 βœ… βœ… βœ… βœ… N/A βœ… βœ… βœ… βœ… βœ… βœ… N/A
CPythonΒ 3.9 βœ… βœ… βœ… βœ… βœ…Β² βœ… βœ… βœ… βœ… βœ… βœ… N/A
CPythonΒ 3.10 βœ… βœ… βœ… βœ… βœ…Β² βœ… βœ… βœ… βœ… βœ… βœ… N/A
CPythonΒ 3.11 βœ… βœ… βœ… βœ… βœ…Β² βœ… βœ… βœ… βœ… βœ… βœ… N/A
CPythonΒ 3.12 βœ… βœ… βœ… βœ… βœ…Β² βœ… βœ… βœ… βœ… βœ… βœ… βœ…β΄
CPythonΒ 3.13Β³ βœ… βœ… βœ… βœ… βœ…Β² βœ… βœ… βœ… βœ… βœ… βœ… N/A
PyPyΒ 3.7 v7.3 βœ… N/A βœ… N/A N/A βœ…ΒΉ βœ…ΒΉ βœ…ΒΉ N/A N/A N/A N/A
PyPyΒ 3.8 v7.3 βœ… βœ… βœ… N/A N/A βœ…ΒΉ βœ…ΒΉ βœ…ΒΉ N/A N/A N/A N/A
PyPyΒ 3.9 v7.3 βœ… βœ… βœ… N/A N/A βœ…ΒΉ βœ…ΒΉ βœ…ΒΉ N/A N/A N/A N/A
PyPyΒ 3.10 v7.3 βœ… βœ… βœ… N/A N/A βœ…ΒΉ βœ…ΒΉ βœ…ΒΉ N/A N/A N/A N/A

ΒΉ PyPy is only supported for manylinux wheels.
Β² Windows arm64 support is experimental.
Β³ Free-threaded mode requires opt-in using CIBW_FREE_THREADED_SUPPORT.
⁴ Experimental, not yet supported on PyPI, but can be used directly in web deployment. Use --platform pyodide to build.

  • Builds manylinux, musllinux, macOS 10.9+ (10.13+ for Python 3.12+), and Windows wheels for CPython and PyPy
  • Works on GitHub Actions, Azure Pipelines, Travis CI, AppVeyor, CircleCI, GitLab CI, and Cirrus CI
  • Bundles shared library dependencies on Linux and macOS through auditwheel and delocate
  • Runs your library's tests against the wheel-installed version of your library

See the cibuildwheel 1 documentation if you need to build unsupported versions of Python, such as Python 2.

Usage

cibuildwheel runs inside a CI service. Supported platforms depend on which service you're using:

Linux macOS Windows Linux ARM macOS ARM Windows ARM
GitHub Actions βœ… βœ… βœ… βœ…ΒΉ βœ… βœ…Β²
Azure Pipelines βœ… βœ… βœ… βœ… βœ…Β²
Travis CI βœ… βœ… βœ…
AppVeyor βœ… βœ… βœ… βœ… βœ…Β²
CircleCI βœ… βœ… βœ… βœ…
Gitlab CI βœ… βœ… βœ… βœ…ΒΉ βœ…
Cirrus CI βœ… βœ… βœ… βœ… βœ…

ΒΉ Requires emulation, distributed separately. Other services may also support Linux ARM through emulation or third-party build hosts, but these are not tested in our CI.
Β² Uses cross-compilation. It is not possible to test arm64 on this CI platform.

To get started, head over to the setup guide.

How it works

This diagram summarises the steps that cibuildwheel takes on each platform to build your package's wheels.

Manylinux container
Test virtualenv
Linux
macOS
Windows
For each version of Python
If tests are configured
{{action.label}}

This isn't exhaustive, for a full list of the things cibuildwheel can do, check the options page.