Definition: WebSocket is a communication protocol that creates a persistent, two-way connection between a client and server.
Unlike normal HTTP request/response communication, either side can send messages whenever needed after the connection is established.

Examples:

  1. Chat: Server instantly sends you a new message.
  2. Online game: Server continuously sends player positions.
  3. Stock dashboard: Server pushes updated prices to the browser.

Back-End My-Journey-In-Codeless