aioftp
ftp client/server for asyncio
What it is and what it does
aioftp is an async-native FTP client and server library built on Python's asyncio, designed to handle file transfer operations concurrently without blocking. It implements a core subset of FTP commands (USER, PASS, PWD, CWD, STOR, RETR, DELE, MLSD, and others) sufficient for typical file operations, with support for both passive mode transfers and concurrent client connections.
The library prioritizes a high-level, extensible API over raw protocol compliance. Clients can recursively list directories, download and upload files, and manage connections using async context managers. Servers can be instantiated with custom path I/O factories for flexible storage backends. The package is actively maintained, requires Python 3.10+, and has no known security vulnerabilities.
Use it for:
- Downloading multiple files from FTP servers concurrently without blocking the event loop.
- Building an async FTP server for file distribution or backup systems within an asyncio application.
- Integrating FTP operations into async web frameworks or data pipelines that already use asyncio.
- Listing and filtering remote FTP directories recursively while handling multiple server connections in parallel.
- Uploading files to FTP servers from async applications without spawning threads or processes.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
aioftp provides an async FTP client and server implementation for Python's asyncio framework, supporting core FTP commands for file transfer, directory operations, and connection management.
Yes. aioftp is production-stable (Development Status 5), actively maintained, has no known vulnerabilities, and integrates cleanly into asyncio-based applications with minimal dependencies. Install it if you need async FTP client or server functionality; the low friction and permissive license make it a straightforward choice for concurrent file transfer tasks.
Install
aioftp on PyPI
pip
pip install aioftpuv
uv add aioftppoetry
poetry add aioftpInstalling aioftp
Before you install
Low install friction with a single lightweight runtime dependency (typing-extensions). Actively maintained with a recent release (10 days old) and an active repository.
License in practice
Apache 2.0 license is permissive, allowing commercial use, modification, and distribution with minimal restrictions—only requiring license and copyright notice preservation.
Quickstart
import asyncio
import aioftp
async def download_files(host, port, login, password):
async with aioftp.Client.context(host, port, login, password) as client:
for path, info in (await client.list(recursive=True)):
if info["type"] == "file":
await client.download(path)
asyncio.run(download_files("example.com", 21, "user", "pass"))
Requires Python 3.10 or later; older versions (0.22.3 supports 3.8, 0.26.3 supports 3.9) available if needed.
Verify before relying
- Whether the optional socks proxy support (via siosocks) is actively maintained or tested in current releases.
- Performance characteristics relative to other async FTP libraries in production workloads.
- Compatibility with non-standard or legacy FTP server implementations beyond the documented fallback to LIST.
Package facts
| License | Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for… (full text in the JSON record) (permissive) |
| Python support | supports the current Python release (>=3.10) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 1 — typing-extensions |
| Maintenance | actively maintained — 10 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 415,509/month — #6,826 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: aioftp-0.28.0-py3-none-any.whl
Tags
More File Transfer Protocol (FTP) packages
PycURL is a Python wrapper around libcurl that…
unclear · top 5,000 on PyPI
tuspyA Python client for uploading files to servers…
permissive · top 5,000 on PyPI
ftputilftputil provides a high-level FTP client…
permissive · top 15,000 on PyPI
pyftpdlibBuilds asynchronous FTP servers in Python with…
unclear · top 15,000 on PyPI
mechanizeAutomate programmatic interaction with HTTP web…
permissive · top 15,000 on PyPI
sftpserverProvides a simple single-threaded SFTP server…
permissive · top 15,000 on PyPI
parfiveParfive downloads multiple files in parallel…
unclear · top 15,000 on PyPI
apache-airflow-providers-ftpProvides FTP integration for Apache Airflow,…
permissive · top 5,000 on PyPI
asynchasynch is an asynchronous ClickHouse driver…
permissive · top 5,000 on PyPI
aiotoolsaiotools provides idiomatic asyncio utilities…
permissive · top 15,000 on PyPI
aioimaplibAn asyncio-based IMAP4rev1 client library that…
copyleft · top 15,000 on PyPI
aiohttp_socksProvides a proxy connector for aiohttp that…
permissive · top 5,000 on PyPI
genie.libs.filetransferutilsProvides utility functions for transferring…
permissive · top 15,000 on PyPI
throttlerProvides rate limiting, concurrency limiting,…
permissive · top 5,000 on PyPI