Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

pillow-rs

Rust image processing with a familiar Python PIL interface and one WebAssembly package for Node.js and browsers.

Documentation · API support · Benchmarks · Rust guide

Current candidate: 12.2.0-alpha.1 (unreleased). Cargo, npm, Python, and this documentation use the same declared version. The base version tracks the targeted Pillow release; alpha.1 identifies this project's first candidate for that target. Matching version numbers do not imply complete compatibility. Read maturity and limitations before replacing Pillow in an application.

This candidate removes deprecated Rust interfaces and the former Python import bridge. See the migration guide and release checklist. Published-release evidence retains the version and revision actually measured.

Choose your package

The registry commands below apply after this candidate is published. To try it now, build from source.

Use case Install Entry point
Python image processing python -m pip install pillow-rs==12.2.0-alpha.1 from PIL import Image
Node.js or a browser npm install pillow-rs@12.2.0-alpha.1 import init, { Image } from 'pillow-rs'
Rust application cargo add pillow-rs@=12.2.0-alpha.1 pillow_rs::Image

The release workflow builds Python wheels for Linux x86-64 (glibc 2.28+), macOS ARM64, and Windows x86-64. Other platforms may build from the source distribution; they are outside the wheel matrix. Rust source builds use Rust 1.96.1. See installation for runtime requirements.

Make your first image

Use a fresh Python environment. Both Pillow and pillow-rs provide PIL, so install them in separate environments.

python3 -m venv .venv
.venv/bin/python -m pip install pillow-rs==12.2.0-alpha.1

On Windows, use .venv\Scripts\python.exe instead of .venv/bin/python.

from io import BytesIO
from PIL import Image, ImageOps

image = Image.new("RGB", (3, 2), (255, 12, 34))
image = ImageOps.mirror(image).resize((6, 4))
output = BytesIO()
image.save(output, format="PNG")
assert image.size == (6, 4)
assert output.getvalue().startswith(b"\x89PNG\r\n\x1a\n")

Continue with Python recipes, JavaScript and browser integration, or Rust integration.

What to expect

  • Creation, transformations, drawing, filters, color, and font operations have a fixed public contract. The API inventory identifies every selected path and its input cases.
  • Python uses familiar PIL imports. JavaScript exposes an explicitly initialized WASM API; it does not reproduce Python syntax or objects.
  • The Rust core uses image-slash-star for codecs and fontdone for fonts.
  • CPU, SIMD, and optional GPU execution have different measured support. A passing comparison does not by itself establish native GPU execution.
  • This alpha does not promise complete Pillow replacement, hardened decoding of arbitrary hostile inputs, or a stable API.

Performance you can inspect

The benchmark site shows workload timings, sample counts, spread, correctness gates, and actual backends. Historical results retain their source revision. Missing measurements remain unavailable. There is no single project-wide speedup claim.

Read the measurement protocol to reproduce a run. Benchmark budget acceptance is separate from correctness and publication.

Contribute

Bug reports, small reproductions, documentation improvements, and input-driven parity fixes are welcome. Start with CONTRIBUTING.md.

make help
make setup-venv PYTHON=python3.12
make build-parity
make migration-parity-test

For documentation only, use make docs-setup, make docs-build, and make docs-serve. Each repository builds and publishes its own GitHub Pages site. The command reference explains side effects and scope.

Project information

The project is distributed under the MIT-CMU License. Dependencies and fixture assets retain their own licenses and notices.

Acknowledgements

Thank you to Puhu for the Rust/Python image processing work that informed the early exploration of this project, and to Pillow and its contributors for the image library, public API, and reference behavior on which the compatibility work depends.

Release files for pillow-rs 12.2.0a1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pillow-rs 12.2.0a1
File Size Uploaded
pillow_rs-12.2.0a1.tar.gz 4.6 MB Details

Built distributions (wheels)

Table of built distributions (wheels) for pillow-rs 12.2.0a1
File Interpreter ABI Platform
pillow_rs-12.2.0a1-cp38-abi3-win_amd64.whl CPython 3.8 abi3 Windows x86-64 Details
pillow_rs-12.2.0a1-cp38-abi3-manylinux_2_28_x86_64.whl CPython 3.8 abi3 Linux glibc 2.28+ x86-64 Details
pillow_rs-12.2.0a1-cp38-abi3-macosx_11_0_arm64.whl CPython 3.8 abi3 macOS 11.0+ ARM64 Details

Total release size: 17.9 MB

Release files / pillow_rs-12.2.0a1.tar.gz

Download URL pillow_rs-12.2.0a1.tar.gz
Size 4.6 MB
Tags Source
SHA-256 checksum
How to use checksums
53449c8986c668a160f846de29b3b9dc947f0a6381240cef85242453886f7f0f
BLAKE2b-256 checksum
How to use checksums
f4eb3ff9d70f534bb5e28782e8ef3fb64d95738d4a37b941755cacb76fbdf0d7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 16, 2026.

Transparency log

Release files / pillow_rs-12.2.0a1-cp38-abi3-win_amd64.whl

Download URL pillow_rs-12.2.0a1-cp38-abi3-win_amd64.whl
Size 4.5 MB
Tags CPython 3.8 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
665510df54e4b0a196e9c380fa98d7bc53de89526f92a098507ced7c27d83213
BLAKE2b-256 checksum
How to use checksums
f9b6d92c8ff19576c0c7ba605f94e2486622ac486f17b7b086b8c897706c83df
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 16, 2026.

Transparency log

Release files / pillow_rs-12.2.0a1-cp38-abi3-manylinux_2_28_x86_64.whl

Download URL pillow_rs-12.2.0a1-cp38-abi3-manylinux_2_28_x86_64.whl
Size 4.7 MB
Tags CPython 3.8 Linux glibc 2.28+ x86-64 abi3
SHA-256 checksum
How to use checksums
f6370e3bff34426157fc54835fbfbb3ac04986070e89bf6d0d2d4c999335caf2
BLAKE2b-256 checksum
How to use checksums
c730c8a427a683b2af8eadfcc9dba2559704b7b506d9d31652473995d756b882
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 16, 2026.

Transparency log

Release files / pillow_rs-12.2.0a1-cp38-abi3-macosx_11_0_arm64.whl

Download URL pillow_rs-12.2.0a1-cp38-abi3-macosx_11_0_arm64.whl
Size 4.1 MB
Tags CPython 3.8 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
9eb8481a5044a5751320bcf2cd024e9b83735f16758dd396f900a98c6c48a178
BLAKE2b-256 checksum
How to use checksums
79b30dd4bfc4f4a9311727289ab8cb49d4a623e4a8aba70f4d7e35c8835f2768
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 16, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

12.2.0a1 This release

4 release files

0.1.3

4 release files

0.1.2

4 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page