Database / Supabase basics Interview Questions
Which is better for real-time collaboration, Supabase Realtime or client-side polling, and why?
Polling means the client repeatedly re-runs a query on an interval (say, every 3 seconds) to check for changes, while Supabase Realtime pushes a message over an already-open WebSocket the instant a matching row changes. For most collaborative use cases — shared cursors, live comments, presence indicators — Realtime is the better fit on nearly every axis: lower latency (changes appear in milliseconds rather than waiting for the next poll interval), lower database load (no repeated queries hitting Postgres from every connected client), and lower bandwidth (only actual changes are sent, not the full result set each time).
Polling still has a legitimate niche: it's simpler to reason about, doesn't require managing a persistent connection, and can be preferable for infrequent updates where sub-second latency doesn't matter, or in environments where WebSocket connections are unreliable (some restrictive corporate proxies, for instance). It also degrades more predictably under connection loss, since a client just tries again on the next interval rather than needing reconnection and resubscription logic.
In practice, most teams default to Realtime for anything genuinely collaborative and reserve polling for background, low-frequency checks like periodically refreshing a dashboard that doesn't need to feel live.
Invest now in Acorns!!! 🚀
Join Acorns and get your $5 bonus!
Acorns is a micro-investing app that automatically invests your "spare change" from daily purchases into diversified, expert-built portfolios of ETFs. It is designed for beginners, allowing you to start investing with as little as $5. The service automates saving and investing. Disclosure: I may receive a referral bonus.
Invest now!!! Get Free equity stock (US, UK only)!
Use Robinhood app to invest in stocks. It is safe and secure. Use the Referral link to claim your free stock when you sign up!.
The Robinhood app makes it easy to trade stocks, crypto and more.
Webull! Receive free stock by signing up using the link: Webull signup.
More Related questions...
