Hotmail uses web sockets. Web sockets requests are different from http request in a way that a web socket connection is persistent all the time while the user is on the website. So the communication goes like this in shortly: The first time the user opens your website he sends http request to your server. Since the http protocol is on the 7th layer of the OSI Model, the request goes through the TCP layer and establishes a socket connection (which is on the 5th layer of OSI Model) with the server. Using the appropriate server-side web sockets technology, the server can use this persistent socket connection with the client to push data when it's needed.
Depending on what language are you using for your back end you can use several different technologies/libraries for implementing web sockets. For asp.net web application you could use Microsoft's SignalR. If you use javscript (Node.js) for your back-end than you can use Socket.io. Note that you can also use Socket.io even if you are not using node.js for your back-end but the implementations won't be as trivial because you would now have 2 different severs which will will potentially need to share data (Ex: sessions or database).
The good thing about Node.js and SignalR is that they are very performant and very scalable to many users, especially Node.js. Another great feature of both this technologies is that if the client's browser doesn't support web sockets they have appropriate fallback methods, like Server Sent Events, Ajax polling, Ajax long polling, Hidden iframe element...
For further reading I recommend this Stackoverflow question