skillfed

numcodecs

A Python package providing buffer compression and transformation codecs for use in data storage and communication applications.

numcodecs v0.16.5 9.6M downloads/30d#1,518 on PyPI149
Permissive license MIT Active released

What it is and what it does

Numcodecs is a Python library for encoding and decoding data buffers using various compression and transformation algorithms. It sits between raw data and storage or transmission layers, allowing you to compress arrays and binary data efficiently. The package wraps multiple codec implementations and provides a consistent interface for applying them.

Typically used in data science and storage applications where you need to reduce data size or apply reversible transformations before persisting or transmitting arrays. It depends on numpy for array handling and typing_extensions for type hints, and supports modern Python versions from 3.11 onward. The library is actively maintained and available as precompiled wheels for common platforms.

Use it for:

  • Compress large numerical arrays before writing to disk in data pipelines
  • Apply reversible data transformations in zarr-based storage systems
  • Reduce network bandwidth when transmitting binary data between services
  • Implement custom codec chains for specialized data encoding workflows
  • Integrate compression into HDF5 or other hierarchical data formats

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Numcodecs provides buffer compression and transformation codecs for efficient data storage and communication, with support for multiple compression algorithms and data transformations.

Yes. Numcodecs is actively maintained, has no known vulnerabilities, uses a permissive MIT license, and ranks in the top 5000 PyPI packages by download volume. Medium install friction is acceptable for a compiled library. Install it if you need flexible buffer compression or data transformation codecs in storage or communication applications.

Install

numcodecs on PyPI

pip

pip install numcodecs

uv

uv add numcodecs

poetry

poetry add numcodecs

Installing numcodecs

Before you install

Medium install friction due to compiled wheels for multiple Python versions and platforms. Active maintenance with recent commits; last release 266 days ago and repository shows ongoing development.

License in practice

MIT license permits free use, modification, and distribution with minimal restrictions, making it suitable for both open-source and commercial projects.

Quickstart

pip install numcodecs
import numcodecs
codec = numcodecs.Blosc(cname='zstd', clevel=5)
compressed = codec.encode(data)
decompressed = codec.decode(compressed)

Requires Python 3.11 or later; numpy and typing_extensions are runtime dependencies.

Verify before relying

  • Specific compression algorithms and codecs available beyond what the fact sheet describes
  • Performance characteristics or compression ratio benchmarks for different codec types
  • Integration patterns with zarr or other storage systems mentioned in repository URL

Package facts

License MIT (permissive)
Python support supports the current Python release (>=3.11)
Install friction medium — platform-specific wheel
Runtime dependencies 2 — numpy, typing_extensions
Maintenance actively maintained — 266 days since the last release
Last repo commit
First released
Downloads 9,611,399/month — #1,518 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: numcodecs-0.16.5-cp311-cp311-macosx_10_13_x86_64.whl; numcodecs-0.16.5-cp311-cp311-macosx_11_0_arm64.whl; numcodecs-0.16.5-cp311-cp311-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl; numcodecs-0.16.5-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl; numcodecs-0.16.5-cp311-cp311-win_amd64.whl; numcodecs-0.16.5-cp312-cp312-macosx_10_13_x86_64.whl; numcodecs-0.16.5-cp312-cp312-macosx_11_0_arm64.whl; numcodecs-0.16.5-cp312-cp312-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl; numcodecs-0.16.5-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl; numcodecs-0.16.5-cp312-cp312-win_amd64.whl; numcodecs-0.16.5-cp313-cp313-macosx_10_13_x86_64.whl; numcodecs-0.16.5-cp313-cp313-macosx_11_0_arm64.whl; numcodecs-0.16.5-cp313-cp313-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl; numcodecs-0.16.5-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl; numcodecs-0.16.5-cp313-cp313-win_amd64.whl; numcodecs-0.16.5-cp314-cp314-macosx_10_13_x86_64.whl; numcodecs-0.16.5-cp314-cp314-macosx_11_0_arm64.whl; numcodecs-0.16.5-cp314-cp314-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl; numcodecs-0.16.5-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl; numcodecs-0.16.5-cp314-cp314-win_amd64.whl

Development Status :: 4 - BetaIntended Audience :: DevelopersIntended Audience :: Information TechnologyIntended Audience :: Science/ResearchOperating System :: UnixProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3 :: OnlyTopic :: Software Development :: Libraries :: Python Modules

Tags

buffer compression codecsdata compression librarycodec for data storagearray compressiondata transformation codecs
compressiondata-storagecodecs

More Python Modules packages