magic-wormhole
Securely transfer data between computers
What it is and what it does
Magic Wormhole is a tool for securely moving files, directories, or short text between two computers without requiring prior setup, shared infrastructure, or manual configuration. The sender generates a short, human-pronounceable code (like a passphrase) that the receiver types into their machine; the two endpoints then establish an encrypted connection and transfer the data. The codes are single-use, do not need memorization, and support tab-completion to minimize typing.
The package works as both a command-line utility and a Python library, making it suitable for ad-hoc transfers as well as programmatic integration. It relies on end-to-end encryption (via pynacl and cryptography), a relay server for initial connection brokering, and the Twisted networking framework for asynchronous I/O. The tool is designed for simplicity and security: no accounts, no passwords, no pre-shared keys—just a code.
Use it for:
- Send a file or folder to a colleague without setting up cloud storage or email
- Programmatically transfer data between two Python applications on different machines
- Securely share sensitive files with end-to-end encryption and no persistent server storage
- Quickly move a directory tree across a network without SSH or rsync setup
- Integrate encrypted peer-to-peer file transfer into a Python application
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Magic Wormhole transfers files, directories, and text between computers using short, human-readable codes and end-to-end encryption, with both a command-line tool and a Python library.
Yes. Magic Wormhole is actively maintained, has no known vulnerabilities, low install friction, and solves a real problem—secure, code-based file transfer with minimal setup. The MIT license is permissive. Install it if you need to move files between machines without pre-arrangement or if you want to add encrypted transfer to a Python application. The only caveat is that it depends on external relay infrastructure (mailbox and transit servers) that you do not control; verify those services remain available for your use case.
Install
magic-wormhole on PyPI
pip
pip install magic-wormholeuv
uv add magic-wormholepoetry
poetry add magic-wormholeInstalling magic-wormhole
Before you install
Low install friction with a pure-Python wheel. Active maintenance as of 2026-07-26 with 22816 repository stars. Requires Python 3.10 or higher and depends on 15 runtime packages including cryptographic libraries (pynacl, cryptography) and networking stacks (twisted, autobahn).
License in practice
Released under the MIT license (permissive), allowing use in both open-source and proprietary projects with minimal restrictions.
Quickstart
pip install magic-wormhole
from wormhole import create
wormhole_code = create() # generates a code to share
# or use the CLI: wormhole send <file>
Requires Python 3.10 or higher; depends on system-level networking and cryptographic libraries that twisted and pynacl may require compilation for on some platforms.
Verify before relying
- Whether the mailbox server and transit relay infrastructure remain publicly available and maintained
- Performance characteristics when transferring very large files or directories
- Whether pywin32 dependency affects non-Windows installation or is conditionally installed
Package facts
| License | MIT (permissive) |
| Python support | supports the current Python release (>=3.10) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 15 — spake2, pynacl, attrs, twisted, autobahn, automat, cryptography, tqdm, click, humanize, txtorcon, zipstream-ng, iterable-io, qrcode, pywin32 |
| Maintenance | actively maintained — 101 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 684,088/month — #5,359 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: magic_wormhole-0.24.0-py3-none-any.whl
Tags
More Utilities packages
Converts domain names between Unicode and…
permissive · top 100 on PyPI
charset-normalizerDetects and normalizes text encoding from…
permissive · top 100 on PyPI
setuptoolsSetuptools is a Python build backend and…
permissive · top 100 on PyPI
pluggyPluggy provides a plugin system that lets you…
permissive · top 100 on PyPI
PygmentsPygments is a syntax highlighter that colorizes…
permissive · top 100 on PyPI
sixSix provides utility functions to write Python…
permissive · top 100 on PyPI
python-olmPython bindings for the Olm cryptographic…
permissive · top 5,000 on PyPI
wakeonlanSends wake-on-LAN magic packets to power on…
permissive · top 15,000 on PyPI
pysmbpysmb implements the SMB/CIFS protocol to let…
permissive · top 5,000 on PyPI
sendsafelyIntegrates SendSafely secure file transfer and…
permissive · top 15,000 on PyPI
xmodemImplements the XMODEM file transfer protocol…
permissive · top 15,000 on PyPI
daveyImplements the Discord Audio & Video End-to-End…
permissive · top 5,000 on PyPI
django-magiclinkAdds passwordless email-based authentication to…
permissive · top 15,000 on PyPI
aws-encryption-sdk-cliCommand-line tool to encrypt and decrypt files…
permissive · top 15,000 on PyPI
keyrings.cryptfileA keyring backend that stores passwords in an…
permissive · top 15,000 on PyPI
python-magic-binIdentifies file types by examining file headers…
permissive · top 15,000 on PyPI