Same-Site Cookies
The SameSite attribute is a browser setting attached to a cookie that tells the browser whether to send that cookie when a request comes from another website. It is primarily a security control that helps limit how cookies travel between different sites, reducing certain cross-site attacks. It is a technical mechanism rather than a consent or privacy-law feature in itself.
SameSite is an attribute set on a cookie (via the Set-Cookie response header) that instructs the browser on whether to include the cookie with cross-site requests, thereby distinguishing first-party from third-party cookie contexts. Its recognized values are Strict, Lax, and None, where None permits the cookie to be sent with both cross-site and same-site requests but generally requires the Secure attribute to also be set. The attribute's primary purpose is security, mitigating cross-site request forgery (CSRF) and unintended cross-origin information disclosure by controlling cross-site transmission. Note that SameSite governs cookie transmission behavior at the browser level and does not, by itself, address consent obligations under the ePrivacy Directive or the processing of personal data under the GDPR; those legal requirements are out of scope for this attribute and must be handled separately.
Why it matters
The SameSite attribute is one of the primary browser-level mechanisms for controlling whether a cookie is sent with requests originating from other websites. Its main purpose is security: by restricting cross-site transmission, it helps mitigate cross-site request forgery (CSRF) and unintended cross-origin information disclosure. For teams building and maintaining web applications, correctly setting SameSite values is a practical safeguard against certain classes of cross-site attacks.
SameSite also matters because it draws a technical line between first-party and third-party cookie contexts, which increasingly overlaps with how privacy and consent are managed in practice. Cookies set with SameSite=None are, in effect, permitted to travel in cross-site contexts and therefore commonly correspond to the third-party tracking scenarios that attract consent obligations. However, it is important not to overstate this relationship: SameSite is a transmission control, not a consent or privacy-law feature. Setting or restricting SameSite does not, by itself, satisfy or discharge any legal obligation.
For compliance and legal teams, the key takeaway is scope. SameSite governs browser behavior at the technical level; it does not address consent obligations under the ePrivacy Directive or the processing of personal data under the GDPR. Those requirements must be handled separately through consent management and lawful-basis analysis. Treating SameSite as if it resolves privacy questions would be a misreading of what the attribute does.
Who it's relevant to
Inside Same-Site Cookies
Common questions
Answers to the questions practitioners most commonly ask about Same-Site Cookies.