If you have an Gmail account, you have probably observed that when you visit http://www.gmail.com, sometimes it asks for your username and password, but sometimes it takes you directly into your inbox; Similarly, when you visit http://www.amazon.com, you may be surprised that the front page has your first name on it! How do websites like Google and Amazon keep track of user identity and information? In this article, we are going to explore this topic, and explain how web applications use cookies to track their users over time.
The core technologies that power the Internet are designed such that when you make requests to web servers, for example, Google's front page http://www.google.com
, the web server does not know who you are, nor does it have any memory of its past interactions with you. The protocol that governs the transportation of data between your browser and Google's server, which is called