What Are Cookies & Different Types of Web Cookies, Explained (2024)

What are cookies? They’re small pieces of information that websites store on your computer. But why does it reside in your PC, and what exactly is its purpose? Here’s a closer look at different types of cookies and how they work.

‘What are cookies?’- this question has become ubiquitous ever since GDPR came into effect.

Cookies have been of great importance in the ad tech industry since the advent of digital and programmatic advertising. According to Epsilon, about 80% of advertisers rely on third-party cookies. If those cookies were to disappear, those businesses would need to explore other methods of marketing and advertising that would allow them to reach their target audiences.

What Are Cookies & Different Types of Web Cookies, Explained (1)

However, now the scenario is changing, and the reliance upon cookie-based information is about to fade, as Google’s decision to phase-out cookies will take effect in less than a year.

Due to this, publishers and advertisers will have to turn to other solutions for earning ad revenue and serving relevant ads to users.

But, before publishers start to look for other solutions, it is equally important for them to understand how cookies have been functioning in the ad tech industry, as it’ll help them understand the functioning of alternate solutions.

Also Read: What are the Types of Cookieless Data for Publishers

Table of Contents:

What is a Cookie?

Cookies are essentially pieces of code saved by websites onto the user’s web browser when a session is initiated. Cookies have a lot of uses, but the most important ones are session management, user personalization, and tracking.

All websites that use Cookies have agreed that Cookies enhance the browsing experience by allowing a website to store small snippets of data on a user’s device.

By doing so, the website can keep track of a user’s preferences and tailor content accordingly. According to W3 techs, cookies are used by 40.8% of all websites.

Cookies are not programs, they do not perform any functions. These are simple text files that can be opened using Notepad. In ad tech, cookies are used to track users across the web. For instance, if a user visits a website, then the cookies of that website will be saved on the browser.

Now when the user visits the website again after a few days, the website will know it is the same user. Some cookies can track users across websites and devices.

Types of Cookies

First-Party Cookies

First-party cookies are set by the website visited by the user. The data collected using first-party cookies are used for purposes like calculating pageviews, sessions, and the number of users.

Primarily, publishers have access to data collected using first-party cookies, which can later be shared with advertisers or agencies for ad targeting.

Apart from that, analytics tools – like Google Analytics – use first-party cookies to understand user behaviour and present it in tabular or graphical form for the publisher’s understanding.

Third-Party Cookies

Third-party cookies are set by domains that are not directly visited by the user. This happens when publishers add third-party elements (like chatbots, social plugins, or ads) to their websites.

Once installed, third-party cookies also track users and save their information for behavioural targeting. For example: Let’s say that you added a YouTube link to one of your blogs. Whenever this YouTube link gets a click, a YouTube cookie will be added to the user’s browser. This cookie can track him/her until it expires.

Also Read: First-Party vs Third-Party Cookies: What’s the Difference?

Session Cookies

What Are Cookies & Different Types of Web Cookies, Explained (3)

Session cookies either expire immediately or within a few seconds of the user leaving the web browser. Among other uses, these cookies are used by e-commerce websites to remember the product placed in the cart by the user, to keep users logged in, and to calculate each user session for analytical purposes.

For example, if an e-commerce website does not use session cookies, then the items added to the cart will be removed by the time the user reaches the checkout page. And the server will forget the user and treat him/her like a completely new visitor.

Persistent Cookies

As the name suggests, persistent cookies stay on the user’s browser for a very long time. Generally, persistent cookies are required to have an expiration date which could be anything between a second to 10 years. The above-shared screenshot is an example of persistent cookies with an expiration date.

Persistent cookies are used by publishers to track a single user and his/her interaction with their website. These types of cookies are used by 22.9% of all the websites – W3Techs.

To check whether your browser has persistent cookies, try this. If you are logged in to Gmail on the browser, then close the tab(s) and restart your device.

When your device turns back on, open the same browser and visit the same service or account (Gmail); if you are still logged in, then you have persistent cookies saved on the browser, dropped by Google mail service.

Browsers are making it harder to use cookies. Web browsers like Firefox and Safari are updating their products to kill these cookies as soon as users are done with the websites. And Chrome is soon to join this bandwagon and will start blocking third-party cookies by 2022.

Secure Cookies

Only HTTPS websites can set secure cookies, i.e., cookies with encrypted data. Mostly, the checkout or payment pages of e-commerce websites have secure cookies to facilitate safer transactions. Similarly, online banking websites are required to use secure cookies for security reasons.

Use of Cookies in Ad Tech

An average website has 23 cookies. And most of these are third-party persistent cookies.

Since the evolution of programmatic advertising, we have created an ecosystem where ad campaigns require third-party data to be successful. Advertisers purchase second-party and third-party data from publishers and agencies, store them in their DMPs and use it to target the right audience.

Future of Cookies: Insights from Experts

Chrome, along with other web browsers, phasing out third-party cookies is alarming for web publishers. While the industry is trying to understand the future without 3P cookies, some are developing solutions to curb the effects.

The publisher’s revenue will definitely be affected by the removal of 3P cookies. If you look at your Safari CPMs, you will find they are lower than Chrome’s. The same can be true for your Chrome CPMs once the browser removes the use of 3P cookies.

There has never been a better time (partly because of Coronavirus) for publishers to show their value propositions to their users. Explain to your users why you need to show ads or send newsletters to keep up with high quality content.

Rob Beeler, Chairperson at AdMonsters and CEO of Beeler.Tech

Subscription models are going to be the next hit thing in user engagement.

Apart from making essential coverage free during the pandemic, multivariate A/B testing, focus on newsletter blasts, reminding people of our mission and our importance in the moment have worked for us.

Micheal Finnegan, President, Atlantic Media

Once you have your audience on your side, it’s time to optimize the demand.

Re-think, how you think of partners and vendors. In programmatic space, it’s super easy to just sign a contract, put them in your header, see if they work, if not, drop them. Continue to do tests that you have no time to do.

Rob Beeler, Chairperson at AdMonsters and CEO of Beeler.Tech

In hindsight, the use of third-party cookies was not doing any good to ad tech. From invading user privacy to discrepancies in user demographics, third-party cookies have their own list of cons.

Third-party cookies were never the best thing. If you check how all companies perceive you, you will find – I am a man and I am a woman and I am 95 years old and I am 20 and I am buying a car – only some of that is true. But there is a cookie that is allowing me to be whatever they (brands) want me to be and that’s not the best approach. So, better things might be coming down the line.

Rob Beeler, Chairperson at AdMonsters and CEO of Beeler.Tech

These quotes are taken from a webinar we hosted with Rob Beeler. Check the whole webinar here.

What to Read Next:

  • Google’s Privacy Sandbox
  • What are TURTLEDOVE and SPARROW
  • What is PARRROT

Final Thoughts

Cookies have been around for a while now, and most people are pretty comfortable with them. But now, privacy concerns are flying around everywhere, and people are starting to question the way that cookies are used on the internet. However, this is a discussion for another blog post.

We hope by now you have understood what cookies are in the world of the internet, their different types, and their uses.

Frequently Asked Questions

1. What is an example of an internet cookie?


Internet cookie store information that relates to a user’s preferences and behaviour. By keeping track of how users interact with a website, cookies help to provide a smoother and more personalized experience.

2. What are the two types of cookies?

There are two types of cookies:

The first type is the session cookie, which is temporary and only lasts for the duration of the user’s visit to the website.

The second type is the persistent cookie, which is stored on the user’s computer for a longer period of time.

3. What is the difference between third-party cookies and third-party cookies?


First-party cookies are created by the website that you are visiting.
Third-party cookies are created by other websites that have elements on the page that you are visiting. Third-party cookies can be used for advertising or other purposes.

What Are Cookies & Different Types of Web Cookies, Explained (4)

Shubham Grover

Shubham is a digital marketer with rich experience working in the advertisem*nt technology industry. He has vast experience in the programmatic industry, driving business strategy and scaling functions including but not limited to growth and marketing, Operations, process optimization, and Sales.

I am Shubham Grover, a digital marketer with extensive experience in the advertisem*nt technology industry. Throughout my career, I have played a crucial role in driving business strategy, scaling functions such as growth and marketing, operations, process optimization, and sales within the programmatic advertising ecosystem. My expertise lies in understanding the intricate details of ad tech, particularly the role of cookies in the digital advertising landscape.

Now, delving into the concepts presented in the article:

1. What is a Cookie?

  • Cookies are small pieces of code stored by websites on a user's web browser during a session initiation.
  • They serve multiple purposes, including session management, user personalization, and tracking.
  • Approximately 40.8% of all websites use cookies, according to W3Techs.
  • Cookies are not programs but simple text files that can be opened using Notepad.

2. Types of Cookies

  • First-Party Cookies:
    • Set by the website visited by the user.
    • Used for calculating pageviews, sessions, and the number of users.
    • Accessible to publishers and can be shared with advertisers for ad targeting.
  • Third-Party Cookies:
    • Set by domains not directly visited by the user, often due to embedded elements like chatbots, social plugins, or ads.
    • Used for behavioral targeting across websites.
  • Session Cookies:
    • Expire immediately or within seconds of the user leaving the web browser.
    • Commonly used by e-commerce websites for cart management and user session calculation.
  • Persistent Cookies:
    • Remain on the user's browser for an extended period, with a specified expiration date.
    • Used by publishers to track user interactions over time.

3. Secure Cookies

  • Only HTTPS websites can set secure cookies with encrypted data.
  • Commonly used in checkout or payment pages of e-commerce websites for secure transactions.

4. Use of Cookies in Ad Tech

  • An average website has 23 cookies, with a significant portion being third-party persistent cookies.
  • Programmatic advertising relies on an ecosystem where ad campaigns use third-party data for success.
  • Advertisers purchase second-party and third-party data from publishers and agencies for targeting.

5. Future of Cookies: Insights from Experts

  • Browsers like Chrome are phasing out third-party cookies, impacting web publishers' revenue.
  • Publishers need to communicate their value propositions to users, emphasizing the need for ads to support quality content.
  • Subscription models and user engagement strategies are expected to gain prominence in the post-third-party cookie era.

6. Final Thoughts

  • Cookies have been essential for enhancing browsing experiences, but privacy concerns are causing a shift in the digital landscape.
  • The removal of third-party cookies prompts the exploration of alternative revenue models and user engagement strategies.

7. Frequently Asked Questions

  • Example of an Internet Cookie:
    • Internet cookies store information related to user preferences and behavior, providing a personalized experience.
  • Two Types of Cookies:
    • Session cookies (temporary) and persistent cookies (stored for a longer period).
  • Difference Between First-Party and Third-Party Cookies:
    • First-party cookies are created by the visited website, while third-party cookies are created by other websites with elements on the page.

In conclusion, the evolving landscape of cookies in the ad tech industry requires a thorough understanding of their types, usage, and the impending changes brought about by browser decisions like Google's phase-out of third-party cookies. This comprehension is crucial for publishers and advertisers seeking alternative solutions in the evolving digital advertising landscape.

What Are Cookies & Different Types of Web Cookies, Explained (2024)
Top Articles
Latest Posts
Article information

Author: Gregorio Kreiger

Last Updated:

Views: 6439

Rating: 4.7 / 5 (77 voted)

Reviews: 92% of readers found this page helpful

Author information

Name: Gregorio Kreiger

Birthday: 1994-12-18

Address: 89212 Tracey Ramp, Sunside, MT 08453-0951

Phone: +9014805370218

Job: Customer Designer

Hobby: Mountain biking, Orienteering, Hiking, Sewing, Backpacking, Mushroom hunting, Backpacking

Introduction: My name is Gregorio Kreiger, I am a tender, brainy, enthusiastic, combative, agreeable, gentle, gentle person who loves writing and wants to share my knowledge and understanding with you.