Learn Swiftly, What are Cookies in Computer?

We have come across the term ‘cookie’ quite many times while we browse through the internet. Most of the time, the site asks permission to accept cookies or not? So, today in this very article, we will understand the concept of cookies, what they are and what they do, are they useful or harmful, and so on. So, just stay tuned till the end of this very simple article to find out.

What are cookies?

The term cookie has nothing to do with delicious biscuits. We’re talking about a small data package that originated in the UNIX program “fortune cookie”. Cookies are nothing but text files and they contain can store users previously entered into form fields like – ‘usernames’ and ‘passwords’. These cookies give you a specific identity while you surf the net. In simple words, cookies are created by the server in order to serve you better. Based on your interest, cookies are generated by the server while you browse through the net, and then from next time onwards, the server places the information related to your area of interest as soon as you launch the web browser. 

Web servers can use cookies to store information in the web browser. The web server then receives this back with each subsequent website call. Why is this function necessary? If you have ever deleted all cookies from your browser and then selected the “Block all cookies” option, you may be familiar with these situations:

  • You want to register with your favorite social network. You enter your name and password, but each time you click Login you will be prompted to log in again. Your browser doesn’t seem to be able to “remember” your login data.
  • You want to shop in an online shop. You put items in the virtual shopping cart, but as soon as you click on the next web page, all the goods in the shopping cart are gone. Your browser doesn’t seem to be able to “remember” the goods in the shopping basket.

The reason behind the “cannot remember” is the blocked cookies. So without cookies, your browser seems pretty forgetful. Cookies were invented to overcome a shortcoming in the HTTP protocol. HTTP is the language that web browsers and web servers use to communicate to request and receive web pages. The shortcoming: For the webserver, each website call is independent of the previous calls. If the user views two pages in succession with his browser, the web server cannot tell whether these two views come from the same browser. HTTP does not transmit enough information about this.

As of now, we have got a simple understanding of what a cookie means, let us now explore it further. There are generally two types of cookies, namely – ‘Magic Cookies’ and ‘HTTP cookies’. Let us study them briefly. When data packets containing information are shared without any modification, then it is known as ‘Magic Cookies’. ‘HTTP Cookies’ on the other hand are also known as ‘Internet Cookies’ are designed especially for internet browsing and surfing. These are the cookies that all of us face and use while surfing the net.

In short, Cookies are data that a website stores temporarily on your computer when you visit it.

The cookies come from accessed websites such as Amazon or Google and contain information about the language, page settings, e-mail address, and your name.

They are intended to make surfing the Internet easier for you. If the website already knows your login data, you save yourself having to enter long passwords and usernames, for example.

In addition, your surfing habits are saved and passed on to the operator of the website.

Tip: Just take a look to see which cookies a site sets. With Firefox, you can do this via “Settings” > “Privacy and security” > “Cookies” > “Manage data”.

We have got a good understanding of Cookies as of now, let us dive further.’ HTTP Cookies are further classified into two types, and they are – ‘Session Cookies’ and ‘Persistent Cookies’. Let us know in detail about them. ‘Session Cookies’ come into play while you are browsing a website, furthermore, they are stored in RAM (Random Access Memory) and once your browse ends, they are eliminated automatically. So, they are good for the privacy part. ‘Persistent Cookies’ on the other hand reside in your hard disk and are eliminated only when their expiry period comes. Let us know about the two main applications of ‘Persistent Cookies’:

1. I hope all of you might have faced and even used or are still using the auto-login mechanism on various sites, like – Facebook, Email Clients, and so on. This automatic login feature is the attribute of ‘Persistent Cookies’.

2. These Cookies also enable a website to track what numerous visitors have searched for and what are their specific areas of interest in order to serve them better and showcase them whatever they like.

Now, it is the time we discuss the negative impacts of Cookies. But are they really dangerous? Do they pose a serious threat like other malicious software, like – Viruses, etc do? Well, the answer is no, Cookies themselves are not at all harmful nor do they harm your system. So, why are they dangerous then? Or are they not? Now, comes the twist, yes, they are dangerous, but how? Let us find it out. The ability of a Cookie to track a user’s browsing history is where the danger lies. Let us study it briefly.


Good cookies: The session cookies

  Session cookies are particularly helpful and indispensable when surfing the web. They save your login data so that you do not have to log in again after a few seconds on password-protected websites.

  Security is the priority here, which is why cookies are used automatically, for example, in online banking.

  The connection is stored in a cookie for the entire session until you close the website or log out. Then the cookie will also be removed automatically.


Bad cookies: Advertising through tracking cookies

  The unpopular cookies include the “tracking cookies”, which bring you personalized advertising and are stored permanently. They are also often called “persistent cookies”.

  If you open a website with advertising banners, these also place a cookie. Your surfing behavior is thus spied on in order to show you the “best possible” advertising in a targeted manner.

  The real goal, however, is website optimization. For example, you will receive personalized product suggestions from Amazon through cookies.


How to recognize the use of cookies

Even without specific software and settings, it is easy to recognize when a website uses cookies. Whenever a page greets you personally by name or any form of personalized information is used without you have logged in with a username and password, cookies are involved.

Have you ever wondered how a website knows your name and greets you personally? A cookie stored on the hard drive ensures that information about you is collected and read by the server on a second visit. With the cookie, you have a “virtual” customer number, so to speak, which is used to identify you when you visit. But that also has advantages! This makes sure certain pre-settings can be adopted automatically without you having to laboriously enter them from the beginning each time. It also saves expensive online time. Basically, a cookie is nothing more than a small buffer in which information is collected.


How do cookies work?

Cookies are sent to the browser together with the content of the website accessed by the user. When the user enters a web address in the browser or follows a link, the browser technically sends a request to the webserver on which the website is located. The web server answers this request sends back the content of the website and can also send one or more cookies. The browser saves the cookies and displays the website in the browser.

If you later request a website from the same web server, the browser sends the saved cookies of the webserver with the request. In this way, the webserver receives all the cookies that it has stored in the browser each time the website is accessed. Cookies can only be read by our own server. A foreign server “B” cannot reach cookie “A”!


Based on the threat, Cookies are classified into the following types:

First-Party Cookies:

They are usually the safest types of Cookies, as they are developed by the specific website that you are using.

Third-Party Cookies:

They are not developed by the website, rather they are generated by random third-party web pages and they generally appear as links of ads that take you to a completely different site if you launch them. In this way, your browsing history, your privacy is exposed to random individuals or a group of individuals and you will not even know about it.

Zombie Cookies:

They are also a part of third-party cookies and they get installed in your system and are not removed even after you delete them. They also allow random third-party players to access your search history and serve as a gateway to your privacy.



What is meant by Cookies?

They are generally text files and consist of information in the form of – ‘usernames’, ‘passwords’, etc.

What are the different types of Cookies?

Cookies are mainly classified into two types – ‘Magic Cookies’ and ‘HTTP Cookies’.

Currently, we deal with which type of Cookies?

Currently, we deal with ‘HTTP Cookies’, and they are also known as Internet Cookies.

Are Cookies harmful?

They are directed not at all harmful, but they do pose threats in-directly.

Should we allow Cookies?

Well, this is a billion-dollar question, it depends on users. If you do not want to utilize its applications, then you need not allow them, but if you wish to utilize its applications, then you may allow them, but be very careful while surfing the internet.

Can I prevent my data from being read?

This differs from technology to technology. Cookies, for example, can be blocked using the browser, but sometimes at the expense of website usability. The problem, however, is that the user cannot defend himself against many technologies despite the technical possibilities. Often he cannot even see that data is being collected in the background. He can therefore not object to the collection and processing of data.

What is all this information collected for?

This information can be used to create comprehensive profiles. Which pages does the user visit most often? What is he interested in? Cookies remember your preferences and adjust the advertising displayed on websites accordingly.