Browser Cookies: What They Remember About You
A website can remember that you're signed in without storing your password in a cookie. Often, the cookie holds a short ID that lets the site recognize a visit you've already started.
A cookie is a small piece of data stored by your web browser and sent with matching requests to a website. It can help remember a language choice, connect you to a shopping cart, or recognize you across visits.
- Block malware in real time on up to five devices.
- Browse privately on public Wi-Fi with the included VPN.
- Get an alert if your personal details turn up on the dark web.
What goes back and forth
When you open a page, your browser asks a server, a computer providing the website, for information. The server can include an instruction to save a cookie in its reply.
On later requests, the browser sends the cookie when its rules allow. The web cookie standard describes this exchange and the rules that limit which website addresses and parts of a site receive a cookie.
In plain terms, your browser doesn't send every saved cookie to every website.
A cookie might contain a setting directly, such as a preferred language. Or it might contain an identifier that the website uses to find information stored on its own systems.
For example, an online store can connect a cart identifier with a list of products kept on its server. The cookie doesn't need to contain the entire shopping list.
Remembering a visit isn't the same as remembering a password
A session links a series of requests into an ongoing interaction. After you sign in, a session identifier can let the site recognize later requests as part of that signed-in session.
That identifier may function as a temporary credential: something accepted as evidence that you have access. The OWASP session-management guide explains why it needs protection comparable to the sign-in process itself.
How a Stolen Session Can Take Over a YouTube Channel
If someone steals a valid session cookie, they may be able to use your session without knowing your password. What they can do depends on the site's checks and whether the session is still accepted.
Websites can apply protections such as Secure, which restricts sending a cookie to encrypted connections that scramble data in transit, and HttpOnly, which prevents page scripts from reading it. A script is code that runs within a web page.
Those settings reduce particular risks; they don't make an account immune to compromise.
- Learn how you are tracked online and how to cut it down.
- Pick up practical privacy habits you can start today.
- Get advice from someone who once evaded the FBI.
Why some cookies raise tracking concerns
First-party cookies belong to the site you're visiting. Third-party cookies belong to a different site involved in that visit, such as a service supplying an embedded advertisement.
When the same service appears on several sites, a shared identifier can help it connect activity across those sites. Browser restrictions can block or separate those cookies, limiting that connection.
As Mozilla's third-party-cookie guide explains, cross-site cookies also support features such as shared sign-in. Their classification describes the relationship between sites, not a guarantee that one type is harmless and the other is malicious.
Cookies themselves are data, not programs that install a virus. The privacy concern is what the receiving service learns and how it uses that information.
What Do Website Cookies Actually Do?
How long does a cookie last?
A persistent cookie has an expiry date or lifetime that can let it remain between visits. A session cookie has no such explicit lifetime and lasts for the browser-defined session.
Closing the browser isn't a reliable promise that every session cookie disappears. Mozilla's cookie documentation notes that session-restoration features can bring session cookies back when the browser restarts.
The website's signed-in session can also expire separately from the cookie stored in your browser.
Choose what to keep
Your browser's privacy settings let you manage cookies and related site data. Depending on the browser, you can delete data for a particular site, restrict third-party cookies, or make exceptions for features you want to use.
Deleting cookies can sign you out and remove saved preferences, as Google's Chrome guidance explains. It doesn't delete information that a website has already stored about you on its own systems.
Start with the control that matches your concern: restrict cross-site tracking when that's the issue, or clear a particular site's cookies to reset what it saved in your browser. Blocking every cookie may also break sign-ins and other features you use.
Sessions: How the Next Page Remembers Your Visit

Session Hijacking Can Bypass the Password Question

Privacy: What Happens to Your Data After You Share It?

QUOTE:
"Amateurs hack systems, professionals hack people."

