A curated list of awesome ASGI servers, frameworks, apps, libraries, and other resources.
ASGI is a standard interface positioned as a spiritual successor to WSGI. It enables communication and interoperability across the whole Python async web stack: servers, applications, middleware, and individual components.
Born in 2016 to power the Django Channels project, ASGI and its ecosystem have been expanding ever since, boosted by the arrival of projects such as Starlette and Uvicorn in 2018.
This list should help you keep yourself up to date with the most awesome ASGI projects and resources. If you find anything missing, please contribute. ❣️
Contents
Apps and projects that make use of the ASGI interface.
- Datasette - A tool for exploring and publishing data, including ASGI-compatible components and plugins.
Frameworks for building ASGI web applications.
- Bocadillo - Fast, scalable and real-time capable web APIs for everyone. Powered by Starlette. Supports HTTP (incl. SSE) and WebSockets.
- Channels - Asynchronous support for Django, and the original driving force behind the ASGI project. Supports HTTP and WebSockets with Django integration, and any protocol with ASGI-native code.
- FastAPI - A modern, high-performance web framework for building APIs with Python 3.6+ based on standard Python type hints. Powered by Starlette and Pydantic. Supports HTTP and WebSockets.
- Quart - A Python ASGI web microframework whose API is a superset of the Flask API. Supports HTTP (incl. SSE and HTTP/2 server push) and WebSockets.
- Responder - A familiar HTTP Service Framework for Python, powered by Starlette. (ASGI 2.0 only, ed.)
- Starlette - Starlette is a lightweight ASGI framework/toolkit, which is ideal for building high performance asyncio services. Supports HTTP and WebSockets.
Libraries for use in ASGI apps.
- Ariadne - A Python library for implementing GraphQL servers.
- asgiref - ASGI reference implementation, including function wrappers, server base classes and a WSGI-to-ASGI adapter.
- Bonnette - ASGI adapter for Azure Functions.
- Mangum - AWS Lambda & API Gateway support for ASGI.
- tartiflette-starlette - ASGI support for the Tartiflette GraphQL engine.
General-purpose middleware to wrap around ASGI apps.
- datasette-auth-github - GitHub OAuth authentication for ASGI apps. Supports restricting to specific users or member of specific teams or organizations.
- ProxyHeadersMiddleware - Use
X-Forwarded-Proto
andX-Forwarded-For
headers set by a known and trusted proxy to makeclient
andscheme
reference the connecting client (shipped with Uvicorn). - Sentry ASGI - Sentry integration for ASGI frameworks (part of
sentry-sdk
). - Starlette middleware - Middleware for CORS, HTTPS redirection, GZip compression, and more (shipped with Starlette).
- timing-asgi - ASGI middleware to record and emit timing metrics.
Articles, talks and other contents about ASGI.
Articles:
- 2019-03-20 - ASGI 3.0, Andrew Godwin.
- 2018-06-22 - Writing an ASGI web framework, Yoong Kang Lim.
- 2018-06-17 - Embracing ASGI with Quart; Introducing Hypercorn, Philip Jones.
- Undated - Hello ASGI, Tom Christie.
- Undated - Working with ASGI and HTTP, Tom Christie.
Talks:
- 2019-04-12 - Sketching out A Django redesign, Tom Christie, DjangoCon Europe.
- 2018-05 - Taking Django Async, Andrew Godwin, PyCon.
Web servers for ASGI applications.
- Daphne - An HTTP, HTTP2 and WebSocket protocol server for ASGI, developed to power Django Channels.
- Hypercorn - An ASGI server based on the sans-io hyper, h11, h2, and wsproto libraries. Supports HTTP/1, HTTP/2, WebSockets, ASGI 2.0 and ASGI 3.0. Compatible with asyncio, uvloop and trio worker types.
- Uvicorn - A fast ASGI server based on uvloop and httptools. Supports HTTP/1 and WebSockets.