How Real-Time Updates Work

How Real-Time Updates Work

Short polling, long polling, SSE and WebSockets, and when to use each

What you'll learn

  • Why short polling wastes most requests
  • How long polling and Server-Sent Events work
  • How WebSockets give you a two-way connection
  • Which one to pick for which job

In this video, we'll look at four common ways to send live updates from a server to a browser: short polling, long polling, Server-Sent Events (SSE), and WebSockets. We'll explore how each one works, their limitations, and the trade-offs involved.

By the end, you'll understand when to use each approach for things like live dashboards, chat applications, multiplayer games, and collaborative editors.

More videos

32 short explainers so far, with more on the way

View all videos

Join the Community

roadmap.sh is among the top 10 most starred projects on GitHub and is visited by hundreds of thousands of developers every month.

Top 10 out of 28M!

371K

GitHub Stars

Star us on GitHub
Help us reach #1

+90kevery month

+3.2M

Registered Users

Register yourself
Commit to your growth

+2kevery month

52K

Discord Members

Join on Discord
Join the community

RoadmapsGuidesFAQsYouTube

roadmap.shby@nilbuild

Community created roadmaps, best practices, projects, articles, resources and journeys to help you choose your path and grow in your career.

© roadmap.sh·Terms·Privacy·

ThewNewStack

The top DevOps resource for Kubernetes, cloud-native computing, and large-scale development and deployment.