First-Party vs Third-Party Cookies
SameSite, from Chapter 2, exists specifically because of the distinction this chapter covers. Understanding first-party vs third-party cookies — and why they became a privacy problem serious enough that browsers rewrote their entire cookie-handling behaviour — is the direct setup for Chapter 4's explanation of bounce tracking and the real warning that prompted this course.
What Makes a Cookie "First-Party" or "Third-Party"
The distinction is simple: it's about whether the cookie belongs to the site shown in the address bar, or to some other domain whose content is embedded within that page.
osztromok.com, and a cookie set by osztromok.com itself — a login session, a theme preference — is first-party.
Universally considered legitimate and necessary; no browser restricts these.
This is the category browsers have spent years restricting.
How Cross-Site Tracking Actually Worked
Because the ad network's tracking pixel was embedded on both sites, and the same third-party cookie was sent with both embedded requests, the ad network could build a profile of which sites a specific browser visited — entirely invisible to the user, and without either news-site.com or shopping-site.com needing to cooperate or even know it was happening.
The Browser Response — A Timeline
How Browsers Decide What Counts as "Tracking-Like"
| Approach | How it works | Used by |
|---|---|---|
| Blocklists | A maintained list of known tracker domains; cookies/requests from listed domains are restricted automatically | Firefox (Enhanced Tracking Protection), many ad blockers |
| Heuristics | Behavioural pattern detection — no fixed list, instead watching for patterns that resemble tracking techniques (rapid redirects, storage access patterns) | Safari (ITP), increasingly Chrome |
| Default-deny + opt-in | Third-party cookies blocked unless a site explicitly requests access via a dedicated API, with user-visible permission prompts | The general direction all major browsers are converging toward |
What This Means for Building a Site Today
- Don't rely on third-party cookies for anything important. Increasingly inconsistent across browsers, and Chrome's continued phase-out makes them an unreliable foundation for new features.
- First-party cookies remain fully reliable. Nothing in this chapter's crackdown affects ordinary first-party login sessions, preferences, or any cookie set by the site the user is actually visiting.
- Be deliberate about embedded third-party content. Every embed (ad, widget, video player, analytics script) is a potential third-party cookie source — worth knowing what's actually embedded on your own site and why.
Chapter 3 Quick Reference
- First-party cookie — set by the site in the address bar; never restricted
- Third-party cookie — set by an embedded domain different from the address bar; the target of years of browser restrictions
- Classic tracking mechanism: the same embedded tracker on multiple sites recognises the same visitor across them via a shared third-party cookie
- Timeline: Safari ITP (2017) → Firefox ETP (2019) → Chrome SameSite=Lax default (2020) → ongoing third-party cookie phase-out and heuristic detection
- Blocklists vs heuristics: heuristics can produce false positives on legitimate sites — directly relevant to Chapter 4
- First-party cookies are unaffected by all of this — only cross-site/embedded cookie behaviour is restricted
- Next chapter: bounce tracking and Intelligent Tracking Prevention — the actual mechanism behind the real osztromok.com warning