aiodocker
A simple Docker HTTP API wrapper written with asyncio and aiohttp.
What it is and what it does
aiodocker is an asyncio-native wrapper around the Docker HTTP API, built on aiohttp. It lets you write non-blocking Python code to create, start, stop, and inspect containers and images, manage networks and volumes, and stream logs—all without blocking the event loop. The package exposes Docker's REST endpoints through a Pythonic async interface, so you can integrate Docker operations into concurrent applications like web servers, task queues, or orchestration tools.
The library is lightweight (a single wheel with one dependency) and actively maintained. It supports Python 3.10 through 3.13 and is permissively licensed under Apache 2.0. Use it when you need to automate Docker from async Python code—for example, spinning up test containers in a CI pipeline, managing microservices in a cloud application, or building deployment tooling that doesn't block other concurrent work.
Use it for:
- Spin up and tear down Docker containers in async test fixtures or CI/CD pipelines.
- Build async orchestration or deployment tools that manage multiple containers concurrently.
- Stream container logs and monitor resource usage from an async web service or dashboard.
- Automate Docker image builds and pushes as part of a larger async workflow.
- Integrate Docker operations into async task queues or background job systems.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Provides async/await bindings for the Docker HTTP API, letting you manage containers, images, and other Docker resources from Python asyncio code.
Yes. Low install friction, active maintenance, permissive license, no known vulnerabilities, and a clear use case for anyone building async Python applications that need to control Docker. The single dependency (aiohttp) is itself widely used and stable. Install if you're writing asyncio code and need Docker automation.
Install
aiodocker on PyPI
pip
pip install aiodockeruv
uv add aiodockerpoetry
poetry add aiodockerInstalling aiodocker
Before you install
Low friction: pure Python wheel with a single runtime dependency (aiohttp). Actively maintained as of 79 days ago, supports current Python versions (3.10–3.13).
License in practice
Apache 2.0 permissive license; you can use this in commercial and proprietary projects with minimal restrictions.
Quickstart
pip install aiodocker
import asyncio
import aiodocker
async def main():
docker = aiodocker.Docker()
images = await docker.images.list()
print(images)
await docker.close()
asyncio.run(main())
Requires Python 3.10 or later and a running Docker daemon accessible via the Docker socket or HTTP endpoint.
Verify before relying
- Whether the package works with Docker Desktop, Docker Engine, or both.
- Support for Docker API authentication methods beyond default socket/env configuration.
- Performance characteristics when managing large numbers of containers or images.
Package facts
| License | Apache 2.0 (permissive) |
| Python support | supports the current Python release (>=3.10.0) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 1 — aiohttp |
| Maintenance | actively maintained — 79 days since the last release |
| First released | |
| Downloads | 1,448,642/month — #3,887 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: aiodocker-0.27.0-py3-none-any.whl
Tags
More Distributed Computing packages
gRPC Python is an HTTP/2-based RPC framework…
permissive · top 100 on PyPI
execnetexecnet lets you spawn and communicate with…
permissive · top 1,000 on PyPI
cloudpickleCloudpickle extends Python's standard pickle…
permissive · top 1,000 on PyPI
smart-openProvides a unified, open()-compatible Python…
permissive · top 1,000 on PyPI
portalockerPortalocker provides cross-platform file…
permissive · top 1,000 on PyPI
rayRay is a distributed computing framework that…
permissive · top 1,000 on PyPI
aioazuredevopsFetch data from Azure DevOps API endpoints…
permissive · top 15,000 on PyPI
aioodbcaioodbc provides async/await access to ODBC…
permissive · top 5,000 on PyPI
aiohttp-wsgiRuns WSGI applications like Django and Flask on…
permissive · top 15,000 on PyPI
aioopenexchangeratesAsync client library for fetching currency…
permissive · top 15,000 on PyPI
aioqswAsync Python library for controlling QNAP QSW…
permissive · top 15,000 on PyPI
aiohueAsynchronous Python library for controlling…
permissive · top 15,000 on PyPI
dockerA Python library that lets you programmatically…
permissive · top 1,000 on PyPI
aiooss2Aiooss2 provides an async client for Aliyun OSS…
permissive · top 15,000 on PyPI
docker-pyA Python client library that lets you control…
permissive · top 5,000 on PyPI
pyatagAsynchronous Python library for controlling…
permissive · top 15,000 on PyPI