WebSocket is a way for a browser and a server to keep one connection open and send messages in both directions. The server can send an update as soon as it is ready, without waiting for the browser to ask again each time.

Think of it like keeping a phone call open instead of hanging up and redialing for every sentence. This can help with live chat, shared screens, or rapidly updating dashboards. The connection still needs a network and a server to stay available, and WebSocket is not needed for every website.