by Amit Shekhar · 10 June 2026
How does Token Streaming work?
How Token Streaming works. We will also see why we need it, how the server and the browser talk to each other to make it happen, and where it is used in real systems like ChatGPT and Claude.
Read on Outcome School ↗then come back to lock it in
Before you read, guessWhat must be understood to grasp the concept of streaming?
Ten seconds, a guess, then read — a wrong guess still makes the answer stick.
What this article covers
- What is token streaming
- A quick recap of how an LLM generates text
- Why we need streaming at all
- What is SSE
- How the HTTP connection stays open
- The format of a streamed message
- A full walkthrough from server to screen
- The [DONE] marker that ends the stream
- SSE vs WebSockets
- Token streaming in the real world
The article lives on outcomeschool.com. Read it there, then come back: the tutor in the margin has read it and will answer questions, and the questions below check what stayed.
