zxing-cpp
Python bindings for the zxing-cpp barcode library
Decision gist · record as of 2026-08-14
Yes. The package is actively maintained, marked Production/Stable, has no known vulnerabilities, and offers broad platform coverage via prebuilt wheels. Medium install friction is typical for compiled bindings and not a blocker. Use it if you need barcode reading and writing in Python.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python 3.9 or later; image input and output handling depend on external libraries like OpenCV or PIL, which are not runtime dependencies of zxing-cpp.
- Medium install friction due to compiled C++ bindings; prebuilt wheels available for Python 3.9+ on macOS (Intel and ARM), Linux (x86_64 and aarch64), and Windows (x86_64 and ARM64).
- Building from source requires a C++20 compiler.
License · maintenance · safety
Apache-2.0 (permissive) — Apache-2.0 permissive license allows use in commercial and proprietary projects with minimal restrictions; attribution required.
last release 2026-07-29 (16 days) · last repo commit 2026-08-13 · 1,965 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 860,737 downloads/mo, #4,873 on PyPI
Alternatives
Verify before relying
pip install zxing-cpp
import zxingcpp
# Reading barcodes from an image
barcodes = zxingcpp.read_barcodes(img)
for barcode in barcodes:
print(barcode.text, barcode.format)
# Writing a QR code
qr = zxingcpp.create_barcode('test', zxingcpp.BarcodeFormat.QRCode)
img_array = qr.to_image(scale=5)- Which barcode formats are supported by the read_barcodes and create_barcode functions
- Performance characteristics (speed, memory usage) for large images or batch processing
- Whether to_image() returns a numpy array or requires PIL/Pillow for conversion
What it is and what it does
zxing-cpp is a Python wrapper around the zxing-cpp C++ barcode library, enabling detection and generation of barcodes and QR codes from images. It exposes two main operations: read_barcodes() to detect and decode barcodes in an image (returning text, format, content type, and position), and create_barcode() to generate barcode images in multiple output formats (PNG via array or SVG). The package has no runtime Python dependencies and ships prebuilt wheels for current Python versions on major platforms, making installation straightforward on supported systems.
The bindings are built with nanobind and scikit-build-core, which handle C++20 compilation. Reading requires an image input; writing produces either an image array or SVG string. The library supports configurable parameters like error correction level for QR codes and quiet zone control for SVG output.
Use it for
- Detect and decode barcodes from images in inventory or point-of-sale applications
- Generate QR codes for URLs or product identifiers on demand or in batch
- Automate barcode recognition in document processing or logistics workflows
- Create printable barcode labels with configurable scale and format
- Integrate barcode recognition into image analysis pipelines
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
The package is actively maintained, marked Production/Stable, has no known vulnerabilities, and offers broad platform coverage via prebuilt wheels. Medium install friction is typical for compiled bindings and not a blocker. Use it if you need barcode reading and writing in Python.
Install
zxing-cpp on PyPI
Before you install
Medium install friction due to compiled C++ bindings; prebuilt wheels available for Python 3.9+ on macOS (Intel and ARM), Linux (x86_64 and aarch64), and Windows (x86_64 and ARM64). Building from source requires a C++20 compiler.
Requires Python 3.9 or later; image input and output handling depend on external libraries like OpenCV or PIL, which are not runtime dependencies of zxing-cpp.
License in practice
Apache-2.0 permissive license allows use in commercial and proprietary projects with minimal restrictions; attribution required.
Quickstart
pip install zxing-cpp
import zxingcpp
# Reading barcodes from an image
barcodes = zxingcpp.read_barcodes(img)
for barcode in barcodes:
print(barcode.text, barcode.format)
# Writing a QR code
qr = zxingcpp.create_barcode('test', zxingcpp.BarcodeFormat.QRCode)
img_array = qr.to_image(scale=5)
Verify before relying
- Which barcode formats are supported by the read_barcodes and create_barcode functions
- Performance characteristics (speed, memory usage) for large images or batch processing
- Whether to_image() returns a numpy array or requires PIL/Pillow for conversion
Package facts
| License | Apache-2.0 permissive |
| Python support | Supports the current Python release >=3.9 |
| Install friction | Medium. Platform-specific wheel |
| Runtime dependencies | None |
| Maintenance | Actively maintained 16 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 860,737 / month, #4,873 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Development Status :: 5 - Production/StableIntended Audience :: DevelopersOperating System :: OS IndependentProgramming Language :: Python :: 3Topic :: Multimedia :: Graphics |
Evidence: zxing_cpp-3.1.1-cp310-cp310-macosx_10_15_x86_64.whl; zxing_cpp-3.1.1-cp310-cp310-macosx_11_0_arm64.whl; zxing_cpp-3.1.1-cp310-cp310-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl; zxing_cpp-3.1.1-cp310-cp310-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl; zxing_cpp-3.1.1-cp310-cp310-win_amd64.whl; zxing_cpp-3.1.1-cp310-cp310-win_arm64.whl; zxing_cpp-3.1.1-cp311-cp311-macosx_10_15_x86_64.whl; zxing_cpp-3.1.1-cp311-cp311-macosx_11_0_arm64.whl; zxing_cpp-3.1.1-cp311-cp311-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl; zxing_cpp-3.1.1-cp311-cp311-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl; zxing_cpp-3.1.1-cp311-cp311-win_amd64.whl; zxing_cpp-3.1.1-cp311-cp311-win_arm64.whl; zxing_cpp-3.1.1-cp312-abi3-macosx_10_13_x86_64.whl; zxing_cpp-3.1.1-cp312-abi3-macosx_11_0_arm64.whl; zxing_cpp-3.1.1-cp312-abi3-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl; zxing_cpp-3.1.1-cp312-abi3-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl; zxing_cpp-3.1.1-cp312-abi3-win_amd64.whl; zxing_cpp-3.1.1-cp312-abi3-win_arm64.whl; zxing_cpp-3.1.1-cp313-cp313t-macosx_10_15_x86_64.whl; zxing_cpp-3.1.1-cp313-cp313t-macosx_11_0_arm64.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “barcode reading python”
- zxing-cppReads and writes barcodes and QR codes in images using Python…
- pylibdmtxReads and writes Data Matrix barcodes, accepting image objects, numpy…
- pyzbarDecodes one-dimensional barcodes and QR codes from images using the…
Give your agent the search over MCP, or paste the wish link into any chat.
More Graphics packages
Pillow adds image processing capabilities to Python, providing file format support, efficient pixel data handling, and image manipulation operations.
Install it if you need to work with images in Python—it is the de facto standard for this task.
fonttools manipulates font files in multiple formats (TrueType, OpenType, AFM, Type 1, Mac-specific) and includes TTX, a tool to convert fonts to and from XML text format.
Install it if you need to read, write, or manipulate fonts programmatically or via the TTX command-line tool.
Enables matplotlib figures to display inline directly within Jupyter notebooks and IPython environments instead of in separate windows.
PyMuPDF extracts, renders, converts, and manipulates PDF and other document formats (XPS, EPUB, images, Office files via Pro) with high performance, providing text, tables, images, and metadata with precise layout information.
The AGPL license requires careful review if you are building proprietary software—commercial licensing is available from Artifex.
pypdfium2 is a Python binding to PDFium that enables PDF rendering, inspection, manipulation, and creation through a ctypes interface to Google's PDFium library.
Install it if you need PDF rendering, inspection, or manipulation in Python; the medium install friction is offset by comprehensive platform support.
Altair is a declarative Python library for creating interactive statistical visualizations by writing simple, readable code that compiles to Vega-Lite specifications.
See also pyzxing · qrcode · pyzbar · pylibdmtx · python-escpos · biip · treepoem · nanobind · pyStrich · qreader