In most cases, the connection will be established with WebSocket, providing a low-overhead communication channel between the server and the client. Rest assured! In case the WebSocket connection is not possible, it will fall back to HTTP long-polling. And if the connection is lost, the client will automatically try to reconnect. Scale to multiple servers and send events to all connected clients with ease. Socket.IO is a library that enables real-time, bidirectional and event-based communication between the browser and the server. There are also several client implementation in other languages, which are maintained by the community. The client will try to establish a WebSocket connection if possible, and will fall back on HTTP long polling if not. WebSocket is a communication protocol which provides a full-duplex and low-latency channel between the server and the browser.
Features
- Node.js server
- Javascript client library for the browser
- You can consider the Socket.IO client as a "slight" wrapper around the WebSocket API
- Socket.IO provides additional features over a plain WebSocket object
- It adds additional metadata to each packet
- Socket.IO is not meant to be used in a background service, for mobile applications