If you are familiar with TCP socket connections, you know that for every HTTP request a TCP connection is established and will be closed for a single HTTP request (also for any RESTful endpoints and requests). With Websocket technology a socket is created and all of the data is transferred through a connection. This type of communication is suitable for chat applications.
A chat application with a nice UI is created, and I’ve shared it through GitHub. It’s accessible at: this link