skillfed

channels

Brings async, event-driven capabilities to Django.

channels v4.3.2 6.3M downloads/30d#1,939 on PyPI6,354
Permissive license BSD Active released

What it is and what it does

Channels extends Django beyond its traditional request-response model to support real-time, bidirectional communication protocols like WebSocket and long-polling HTTP. It does this by layering ASGI (Asynchronous Server Gateway Interface) support on top of Django, letting you write async consumers that handle persistent connections using familiar Django patterns—routing, middleware, authentication—rather than forcing you into a separate framework.

The package itself provides the core consumer classes and routing layer; it depends on Django and asgiref for the underlying async infrastructure. For production use, you'll need to pair it with an ASGI application server like Daphne (a separate package from the same Django project) and optionally channels_redis for multi-process channel layers. It's actively maintained by the Django core team, supports Python 3.9+ and Django 4.2 through 6.0, and has no known security vulnerabilities.

Use it for:

  • Build real-time chat or messaging applications where messages appear instantly without page refresh.
  • Implement live notifications or activity feeds that push updates to connected clients.
  • Create collaborative editing or whiteboarding tools that sync changes across multiple users.
  • Offload long-running tasks to background workers while keeping the client connection alive.
  • Stream live data (sensor readings, stock prices, sports scores) to multiple subscribers.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Channels augments Django with WebSocket, long-poll HTTP, task offloading, and async support using familiar Django patterns and a flexible ASGI-based framework.

Yes. Channels is an official Django project with active maintenance, low install friction, no known vulnerabilities, and a permissive license. Install it if you need WebSocket or real-time async support in Django; pair it with Daphne and optionally channels_redis for production. Skip it if your application has no real-time requirements.

Install

channels on PyPI

pip

pip install channels

uv

uv add channels

poetry

poetry add channels

Installing channels

Before you install

Low install friction; pure Python wheel. Actively maintained by Django core team with recent commits and clear security reporting process. Supports current Python versions (3.9+) and recent Django releases (4.2 through 6.0).

License in practice

BSD license is permissive; you can use, modify, and distribute this package with minimal restrictions in commercial and open-source projects.

Quickstart

pip install channels

import channels
from channels.generic.websocket import AsyncWebsocketConsumer

class MyConsumer(AsyncWebsocketConsumer):
    async def connect(self):
        await self.accept()

Requires Django 4.2+ and an ASGI application server (e.g. Daphne) to run; development server alone is insufficient for WebSocket support.

Verify before relying

  • Whether Daphne or another ASGI server is bundled or must be installed separately for production use.
  • Performance characteristics and scaling limits for concurrent WebSocket connections.
  • Specific Redis backend requirements if using channels_redis for multi-process deployments.

Package facts

License BSD (permissive)
Python support supports the current Python release (>=3.9)
Install friction low — pure-Python wheel
Runtime dependencies 2 — Django, asgiref
Maintenance actively maintained — 267 days since the last release
Last repo commit
First released
Downloads 6,288,306/month — #1,939 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: channels-4.3.2-py3-none-any.whl

Development Status :: 5 - Production/StableEnvironment :: Web EnvironmentFramework :: DjangoFramework :: Django :: 4.2Framework :: Django :: 5.1Framework :: Django :: 5.2Framework :: Django :: 6.0Intended Audience :: DevelopersLicense :: OSI Approved :: BSD LicenseOperating System :: OS IndependentProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Programming Language :: Python :: 3.9Topic :: Internet :: WWW/HTTP

Tags

django websocket supportdjango async viewsdjango real-time communicationdjango asgi serverdjango long-pollingdjango background taskswebsocket django integration
websocketasync-ioreal-time

More WWW/HTTP packages