twine
Collection of utilities for publishing packages on PyPI
Decision gist · record as of 2026-08-14
Yes. Twine is the standard, actively maintained tool for publishing Python packages to PyPI. It has low install friction, no known vulnerabilities, permissive licensing, and is widely used across the Python ecosystem. Install it if you publish or maintain Python packages.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python 3.10 or later.
- PyPI credentials (username/password or token) must be configured via .pypirc or environment variables.
- Low friction install with a pure-Python wheel.
License · maintenance · safety
Apache-2.0 (permissive) — Apache-2.0 is permissive; you may use, modify, and distribute twine freely in commercial and private projects provided you include the license notice.
last release 2026-07-27 (18 days) · last repo commit 2026-08-11 · 1,783 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 36,352,430 downloads/mo, #734 on PyPI
Alternatives
Verify before relying
pip install twine
twine upload dist/*- Whether keyring integration supports all credential backends on all platforms (fact sheet lists keyring as a dependency but does not detail scope).
- Specific PyPI-compatible repositories supported beyond PyPI itself.
What it is and what it does
Twine is a command-line utility for uploading Python package distributions (wheels, source distributions) to PyPI or other compatible package repositories. It abstracts away the details of the upload protocol and handles authentication, validation, and error reporting, making it the standard tool for package maintainers to publish their work regardless of which build system (setuptools, poetry, hatch, etc.) they used to create the distributions.
The package depends on a modest set of runtime libraries: requests and requests-toolbelt for HTTP communication, urllib3 for connection pooling, keyring for credential storage, rfc3986 for URL parsing, rich for terminal formatting, packaging for version handling, readme-renderer for README validation, and id for internal identification. It is actively maintained, supports modern Python versions (3.10–3.14), and carries no known security vulnerabilities.
Use it for
- Publish a new Python package to PyPI after building it with any build system.
- Upload a new version of an existing package without managing authentication details manually.
- Validate package metadata and README rendering before uploading to PyPI.
- Automate package releases in CI/CD pipelines with credential management via keyring.
- Upload distributions to private or alternative package repositories compatible with PyPI's upload protocol.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
Twine is the standard, actively maintained tool for publishing Python packages to PyPI. It has low install friction, no known vulnerabilities, permissive licensing, and is widely used across the Python ecosystem. Install it if you publish or maintain Python packages.
Install
twine on PyPI
Before you install
Low friction install with a pure-Python wheel. Actively maintained with a recent release; last commit 2026-08-11 and repository shows 1783 stars. Supports current Python versions (3.10 through 3.14).
Requires Python 3.10 or later. PyPI credentials (username/password or token) must be configured via .pypirc or environment variables.
License in practice
Apache-2.0 is permissive; you may use, modify, and distribute twine freely in commercial and private projects provided you include the license notice.
Quickstart
pip install twine
twine upload dist/*
Verify before relying
- Whether keyring integration supports all credential backends on all platforms (fact sheet lists keyring as a dependency but does not detail scope).
- Specific PyPI-compatible repositories supported beyond PyPI itself.
Package facts
| License | Apache-2.0 permissive |
| Python support | Supports the current Python release >=3.10 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | 9 packagesreadme-rendererrequestsrequests-toolbelturllib3keyringrfc3986richpackagingid |
| Maintenance | Actively maintained 18 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 36,352,430 / month, #734 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Intended Audience :: DevelopersNatural Language :: EnglishOperating System :: MacOS :: MacOS XOperating System :: Microsoft :: WindowsOperating System :: POSIXOperating System :: POSIX :: BSDOperating System :: POSIX :: LinuxProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Programming Language :: Python :: Implementation :: CPython |
Evidence: twine-7.0.0-py3-none-any.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 › “pypi package upload”
- twineTwine uploads Python source and binary distributions to PyPI and…
- pypiserverRuns a minimal PyPI-compatible package server that pip and setuptools…
- flitFlit is a Python packaging tool that simplifies creating and…
Give your agent the search over MCP, or paste the wish link into any chat.
More Build Tools packages
Provides reusable utilities for Python packaging interoperability, including version handling, specifiers, markers, requirements, tags, and metadata parsing according to standards like PEP 440 and PEP 425.
Wraps any iterable to display a real-time progress bar in the terminal or Jupyter notebook, showing iteration count, elapsed time, and estimated time remaining.
pip is the standard installer for Python packages, enabling you to download and install packages from the Python Package Index and other indexes into your Python environment.
Hatchling is a standards-compliant Python build backend that handles packaging, metadata, and distribution of Python projects when configured in a project's pyproject.toml file.
Generates Python gRPC service stubs and message classes from Protocol Buffer definitions, enabling developers to build gRPC clients and servers.
pre-commit is a framework for installing and running git hooks written in any language before commits are made, automating code quality and validation checks across multi-language projects.
Install it if your team needs consistent, automated validation at commit time.
See also build · pymaven-patch · virtualenv · setuptools-scm · distlib · setuptools · pypiserver · dbt-common · installer