Skip to the content
Know your tech before you buy it. Makers: get listed from $49/mo

Twine

twine.readthedocs.io

  • Free plan
  • Windows
  • macOS
  • Linux

What Twine is

Twine is a free tool for publishing Python packages to PyPI and other configured repositories, including TestPyPI and private registries. It uploads source and binary distribution files that have already been built, so the upload step does not require it to run setup.py. This also allows distributions to be checked before release. Twine accepts packaging formats including wheels, and its check command checks whether a distribution’s long description will render correctly on PyPI. It authenticates to PyPI over a verified HTTPS connection and can sign files with GPG or upload files signed in advance. Repository settings can come from a .pypirc file, command-line options, or environment variables, including for CI or build servers. Twine can store credentials with keyring, though headless Linux systems may need extra setup to store secrets securely. It supports Linux, macOS, and Windows, requires Python 3.10 or later, and is licensed under Apache-2.0. Twine focuses on publishing: it does not provide lockfile support, environment management, or dependency groups.

Who it suits

Twine suits developers who need to upload built Python distributions to public or private package repositories. It fits publishing workflows rather than dependency or environment management.

Good to know, and what to watch

  • Uploads distributions without running setup.py.
  • Supports formats including wheels.
  • Can publish to PyPI, TestPyPI, and configured repositories.
  • Verified HTTPS connection to PyPI.
  • Supports GPG signing and pre-signed files.
  • Requires Python 3.10 or later.
  • Headless Linux may need extra keyring setup.
  • No lockfile support.
  • No environment management or dependency groups.

Twine

Free

Free plan

The verdict

Twine is a focused publishing tool for built Python package distributions, with checks, signing, and repository configuration options. It does not cover dependency or environment management, so those tasks need separate tools.

What the maker publishes

Automation
The documentation notes that environment-variable configuration can be useful on CI or build servers. source
Build independence
Twine uploads already-built distribution files without requiring it to run setup.py. source
Build workflow
Twine uploads files that have already been created, so distributions can be tested before release without executing setup.py during upload. source
Configuration
Twine accepts repository settings from a .pypirc file, command-line options, or environment variables. source
Configuration
Repository settings can be supplied through a .pypirc file, command-line options, or environment variables. source
Credential storage
Twine supports storing repository usernames and passwords with keyring; headless Linux systems may need additional setup to store secrets securely. source
Credential storage
Twine supports storing repository usernames and passwords securely using keyring. source
Distribution checks
The twine check command checks whether a distribution’s long description will render correctly on PyPI. source
File signing
Twine supports signing uploads with GPG and can upload pre-signed .asc files. source
Intended users
PyPI classifies Twine’s intended audience as developers. source
Keyring limitation
The documentation says keyring may require additional setup on some systems, especially Linux headless environments. source
License
The package is licensed under Apache-2.0. source
Package checks
The twine check command checks whether a distribution’s long description will render correctly on PyPI. source
Package formats
Twine supports any packaging format, including wheels. source
Package uploads
It uploads source and binary distribution files independently of the build system. source
Purpose
Twine publishes Python packages to PyPI and other repositories by uploading source and binary distribution artifacts. source
Purpose
Twine is a utility for publishing Python packages to PyPI and other repositories. source
Repositories
Twine can upload to PyPI, TestPyPI, and other configured package repositories. source
Repositories
Twine documentation shows uploading to PyPI, Test PyPI, and other package indexes configured by repository name or URL. source
Runtime requirement
The package requires Python 3.10 or later. source
Secure connection
Twine authenticates to PyPI over HTTPS using a verified connection. source
Security
The documentation says Twine authenticates to PyPI over HTTPS using a verified connection. source
Signing
Twine supports signing files with GPG and uploading files that were signed in advance. source
Supported formats
Twine supports uploading any packaging format, including wheels. source

Checked against the maker's pages on 8 Oct 2026.