types-cryptography
Typing stubs for cryptography
What it is and what it does
types-cryptography is a PEP 561 type stub package that provides type information for the cryptography library. It allows static type checkers to understand and validate the types of cryptography's public API when used in code, enabling IDE autocompletion and catching type errors before runtime.
The package is generated from typeshed, the community-maintained repository of type stubs for popular Python libraries. However, the cryptography package itself has included native type annotations since version 3.4.4, so this stub package is now primarily useful only if constrained to an older version of cryptography. The description explicitly recommends uninstalling this package if using cryptography 3.4.4 or newer.
Use it for:
- Type-checking a codebase using cryptography < 3.4.4 with a PEP 561-compatible type checker.
- Enabling IDE type hints and autocompletion for cryptography when using older cryptography versions.
- Validating cryptographic code in CI/CD pipelines running static type analysis on projects locked to pre-3.4.4 cryptography.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Provides PEP 561 type stubs for the cryptography package, enabling static type checkers to validate code using cryptography.
No, unless you are locked to cryptography < 3.4.4. The cryptography package has included its own type stubs since version 3.4.4, making this package redundant for modern setups. The package has not been updated since 2022-11-08, and the description explicitly recommends uninstalling it if using cryptography 3.4.4 or newer.
Install
types-cryptography on PyPI
pip
pip install types-cryptographyuv
uv add types-cryptographypoetry
poetry add types-cryptographyInstalling types-cryptography
Before you install
Low install friction with no runtime dependencies. Maintenance is active, though the package has not had a release since 2022-11-08; the description notes that cryptography has included its own type stubs since version 3.4.4, potentially making this package redundant.
License in practice
Licensed under Apache-2.0 (permissive), imposing no significant restrictions on use or distribution.
Quickstart
pip install types-cryptography
# Type checker will now resolve types for cryptography imports
Only useful if you are using a type checker and have cryptography version < 3.4.4; newer versions of cryptography include their own type stubs.
Verify before relying
- Whether installing this alongside cryptography >= 3.4.4 causes type-checking conflicts or is simply redundant.
- Current maintenance status and whether updates are expected given the 2022-11-08 release date.
Package facts
| License | Apache-2.0 license (permissive) |
| Python support | not specified |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | none |
| Maintenance | actively maintained — 1,375 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 2,132,004/month — #3,267 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: types_cryptography-3.3.23.2-py3-none-any.whl
Tags
More Cryptography packages
Certifi provides Mozilla's curated collection…
copyleft · top 100 on PyPI
cryptographycryptography provides cryptographic recipes and…
permissive · top 100 on PyPI
rsaPure-Python RSA encryption, decryption,…
permissive · top 1,000 on PyPI
pyOpenSSLpyOpenSSL wraps OpenSSL's SSL/TLS functionality…
permissive · top 1,000 on PyPI
azure-identityProvides Microsoft Entra ID token-based…
unclear · top 1,000 on PyPI
PyNaClPyNaCl provides Python bindings to libsodium…
permissive · top 1,000 on PyPI
types-WerkzeugProvides PEP 561 type stubs for Werkzeug,…
permissive · top 5,000 on PyPI
types-certifiProvides type stubs for the certifi package to…
permissive · top 1,000 on PyPI
types-attrsProvides PEP 561 type stubs for the attrs…
permissive · top 15,000 on PyPI
types-jwtProvides type stubs for the jwt package,…
permissive · top 15,000 on PyPI
types-backportsProvides PEP 561 type stubs for the backports…
permissive · top 15,000 on PyPI
types-orjsonProvides PEP 561 type stubs for the orjson…
permissive · top 15,000 on PyPI
types-clickProvides PEP 561 type stubs for the click…
permissive · top 5,000 on PyPI
types-tornadoProvides PEP 561 type stubs for tornado,…
permissive · top 15,000 on PyPI
data-science-typesProvides PEP-561-compliant type stubs for…
permissive · top 15,000 on PyPI
types-ipaddressProvides type stubs for Python's standard…
permissive · top 15,000 on PyPI