$npx skillfedfor your agent

sse-starlette

SSE plugin for Starlette

Worth itPyPI WWW/HTTPReleased Aug 2026306.5M downloads / moBSD-3-ClausePure Python

Decision gist · record as of 2026-08-14

pure-Python wheel — sse_starlette-3.4.8-py3-none-any.whl
v3.4.8 · released 2026-08-05 · Python >=3.10 · 2 runtime deps: starlette, anyio

Yes. sse-starlette is production-stable (Development Status 5), actively maintained, has no known vulnerabilities, and solves a well-defined problem with minimal dependencies. Install it if you need to add real-time event streaming to a Starlette or FastAPI application and want standards-compliant SSE without building the plumbing yourself.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Requires Python 3.10 or later; must be used within a Starlette or FastAPI application.
  • Low friction install with only two runtime dependencies (starlette and anyio).
  • Actively maintained with a recent release (9 days old) and 846 repository stars.

License · maintenance · safety

BSD-3-Clause (permissive) — BSD-3-Clause is permissive; you can use this in commercial and proprietary projects with minimal restrictions, provided you include the license notice.

last release 2026-08-05 (9 days) · last repo commit 2026-08-05 · 846 stars

0 known vulnerabilities (OSV.dev, 2026-08-14) · 306,536,742 downloads/mo, #135 on PyPI

Verify before relying

pip install sse-starlette

from starlette.applications import Starlette
from starlette.routing import Route
from sse_starlette import EventSourceResponse
import asyncio

async def generate_events():
    for i in range(10):
        yield {"data": f"Event {i}"}
        await asyncio.sleep(1)

async def sse_endpoint(request):
    return EventSourceResponse(generate_events())

app = Starlette(routes=[Route("/events", sse_endpoint)])
  • Whether the package handles backpressure and flow control for slow clients.
  • Performance characteristics under high client concurrency or large event volumes.
  • Behavior and recovery options when network errors occur mid-stream.
Same gist for agents: .md · .json

What it is and what it does

sse-starlette is a production-ready Server-Sent Events implementation for Starlette and FastAPI that lets you stream data from the server to connected clients in real time. It wraps the W3C SSE specification into a simple async interface: you provide an async generator or memory channel, and the library handles formatting, framing, client disconnect detection, and graceful shutdown. The core abstraction is EventSourceResponse, which you return from a route handler; it manages the streaming lifecycle, including automatic ping messages to keep connections alive and cooperative shutdown with configurable grace periods so your generator can send farewell events before the server terminates.

The package depends only on starlette and anyio, making it lightweight and easy to integrate into existing Starlette or FastAPI projects. It supports modern Python async patterns, works correctly in multi-threaded applications and with multiple asyncio event loops, and provides structured event classes (ServerSentEvent, JSONServerSentEvent) for common patterns. Configuration options include ping intervals, send timeouts, custom headers, and shutdown behavior, giving you fine-grained control over streaming semantics.

Use it for

  • Real-time dashboard updates: stream live metrics or status changes to browser clients without polling.
  • Live notifications: push alerts, messages, or events to connected users as they occur.
  • Database result streaming: yield rows from a database query one at a time to the client.
  • Progress tracking: stream completion percentage or status updates for long-running server tasks.
  • Chat or collaborative editing: broadcast messages or document changes to multiple connected clients.

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

Worth it

Yes.

sse-starlette is production-stable (Development Status 5), actively maintained, has no known vulnerabilities, and solves a well-defined problem with minimal dependencies. Install it if you need to add real-time event streaming to a Starlette or FastAPI application and want standards-compliant SSE without building the plumbing yourself.

Install

sse-starlette on PyPI

Before you install

Low friction install with only two runtime dependencies (starlette and anyio). Actively maintained with a recent release (9 days old) and 846 repository stars. Supports current Python versions (3.10–3.13).

Requires Python 3.10 or later; must be used within a Starlette or FastAPI application.

License in practice

BSD-3-Clause is permissive; you can use this in commercial and proprietary projects with minimal restrictions, provided you include the license notice.

Quickstart

pip install sse-starlette

from starlette.applications import Starlette
from starlette.routing import Route
from sse_starlette import EventSourceResponse
import asyncio

async def generate_events():
    for i in range(10):
        yield {"data": f"Event {i}"}
        await asyncio.sleep(1)

async def sse_endpoint(request):
    return EventSourceResponse(generate_events())

app = Starlette(routes=[Route("/events", sse_endpoint)])

Verify before relying

  • Whether the package handles backpressure and flow control for slow clients.
  • Performance characteristics under high client concurrency or large event volumes.
  • Behavior and recovery options when network errors occur mid-stream.

Package facts

LicenseBSD-3-Clause permissive
Python supportSupports the current Python release >=3.10
Install frictionLow. Pure-Python wheel
Runtime dependencies
2 packages
starletteanyio
MaintenanceActively maintained 9 days since the last release
Last repo commit
First released
Downloads306,536,742 / month, #135 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14
Classifiers
Development Status :: 5 - Production/StableEnvironment :: Web EnvironmentIntended Audience :: DevelopersOperating System :: OS IndependentProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Topic :: Internet :: WWW/HTTP

Evidence: sse_starlette-3.4.8-py3-none-any.whl

Tags

Capabilities
server-sent events starlettesse streaming fastapireal-time event streamingasync event broadcastingw3c sse implementationstarlette event sourcelive data streaming python
Topics
real-time-streamingasync-http

Let your AI agent find packages like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.

wish › “server-sent events starlette”

  • sse-starletteProvides Server-Sent Events streaming for Starlette and FastAPI…
  • assistant-streamProvides server-side streaming support for AI chat applications built…
  • starlette-compressMiddleware for Starlette and FastAPI that compresses HTTP responses…

Give your agent the search over MCP, or paste the wish link into any chat.

More WWW/HTTP packages

urllib3 Worth it
PyPI · Libraries · released May 2026

urllib3 is an HTTP client library that provides thread-safe connection pooling, SSL/TLS verification, multipart file uploads, request retries, compression support, and proxy handling for Python applications.

MITpure Python · 3.10+
1.8Bdownloads / mo
requests Worth it
PyPI · Libraries · released May 2026

Requests is a Python HTTP library that simplifies sending HTTP/1.1 requests with automatic handling of headers, authentication, cookies, and response parsing.

Apache-2.0pure Python · 3.10+
1.8Bdownloads / mo
h11 With conditions
PyPI · WWW/HTTP · released Apr 2025

h11 is a pure-Python HTTP/1.1 protocol implementation that handles parsing and serializing HTTP messages without any built-in I/O, letting you integrate it with any network layer you choose.

MITpure Python · 3.8+aging
894.9Mdownloads / mo
httpx Worth it
PyPI · WWW/HTTP · released Dec 2024

HTTPX is a fully featured HTTP client library for Python that provides both sync and async APIs, with support for HTTP/1.1 and HTTP/2, plus an integrated command-line client.

Install it if you are building new projects or modernizing existing ones that rely on HTTP.

BSD-3-Clausepure Python · 3.8+
797.0Mdownloads / mo
httpcore With conditions
PyPI · WWW/HTTP · released Apr 2025

A minimal low-level HTTP client library that sends HTTP requests with thread-safe and task-safe connection pooling, supporting HTTP/1.1, HTTP/2, proxies, and both sync and async interfaces.

BSD-3-Clausepure Python · 3.8+aging
783.6Mdownloads / mo
aiohttp Worth it
PyPI · WWW/HTTP · released Jul 2026

aiohttp is an async HTTP client and server framework built on asyncio, supporting both WebSockets and middleware-based routing for building concurrent web applications.

Install it if you need async HTTP client or server capabilities in asyncio-based applications.

permissive licensecompiled wheel · 3.10+
643.6Mdownloads / mo

See also aiohttp-sse-client · assistant-stream · datastar-py · aiohttp-sse-client2 · httpx-sse · launchdarkly-eventsource · requests-sse · aiohttp-sse · django-eventstream · starlette