Skip to content
Agentmart
Submit a tool

What is Server-Sent Events (SSE)?

Server-Sent Events is a web standard that lets a server push a stream of text events to a client over one long-lived HTTP response, which browsers read through the EventSource interface.

Also written: Server-Sent Events, EventSource, text/event-stream

Explained

Server-Sent Events, usually shortened to SSE, is defined in the HTML Standard. A page opens an EventSource on a URL and the server answers with the text/event-stream content type. The channel is one-directional: the server pushes events and the page does not send messages back on it.

The stream is UTF-8 text. Each event is built from lines with a field name such as data, event, id, or retry, and a blank line ends and dispatches the event. Lines starting with a colon are comments and are ignored, which is why servers can send them as keep-alive pings; the standard suggests roughly every 15 seconds because older proxies may drop idle connections.

If the connection closes, the client reconnects after a delay and sends a Last-Event-ID header holding the last event ID it saw, so the server can resume. A server can stop reconnection by answering with HTTP 204.

One caveat noted in the standard: clients with a per-server HTTP connection limit can run short when a site opens several EventSource connections.

Cross-reference, from the MCP specification's Streamable HTTP page rather than the standard above: in MCP, a server may answer a POST with an SSE stream, and the older HTTP+SSE transport has been replaced.

Primary source

HTML Standard, Section 9.2 Server-sent events (html.spec.whatwg.org), read Oct 26, 2026

This entry paraphrases the page above. Sources change; check it for the current wording.

Listings that use this

The 5 top-ranked listings tagged for Server-Sent Events (SSE). Rank weighs adoption, freshness, documentation and publisher identity; how we rank and grade. Money never changes the order.

Cite this page

What is Server-Sent Events (SSE)?. Agent Mart. https://agentmart.dev/glossary/sse (last updated 2026-10-26)

Written Oct 26, 2026, updated Oct 26, 2026. All glossary terms