{ "@context": "https://schema.org", "@id": "https://webspecification.com/spec/security/cookie-attributes.jsonld", "@graph": [ { "@type": "TechArticle", "@id": "https://webspecification.com/spec/security/cookie-attributes/#article", "headline": "Cookie attributes — Secure, HttpOnly, SameSite", "description": "Every cookie should be Secure, HttpOnly where possible, and have an explicit SameSite. Use __Host- and __Secure- prefixes for session cookies.", "url": "https://webspecification.com/spec/security/cookie-attributes/", "inLanguage": "en", "isPartOf": { "@type": "WebSite", "@id": "https://webspecification.com/#website", "name": "Web Specification Studio", "url": "https://webspecification.com" }, "author": { "@type": "Person", "name": "Web Specification Studio", "url": "https://webspecification.com" }, "publisher": { "@type": "Organization", "@id": "https://webspecification.com/#organization", "name": "Web Specification Studio", "url": "https://webspecification.com" }, "license": "https://creativecommons.org/licenses/by/4.0/", "dateModified": "2026-07-09T00:00:00.000Z", "citation": [ { "@type": "CreativeWork", "name": "draft-ietf-httpbis-rfc6265bis — Cookies: HTTP State Management Mechanism", "url": "https://datatracker.ietf.org/doc/html/draft-ietf-httpbis-rfc6265bis", "publisher": { "@type": "Organization", "name": "IETF" } }, { "@type": "CreativeWork", "name": "MDN — Set-Cookie", "url": "https://developer.mozilla.org/en-US/docs/Web/HTTP/Reference/Headers/Set-Cookie", "publisher": { "@type": "Organization", "name": "MDN" } }, { "@type": "CreativeWork", "name": "OWASP — Session Management Cheat Sheet", "url": "https://cheatsheetseries.owasp.org/cheatsheets/Session_Management_Cheat_Sheet.html", "publisher": { "@type": "Organization", "name": "OWASP" } }, { "@type": "CreativeWork", "name": "web.dev — SameSite cookies explained", "url": "https://web.dev/articles/samesite-cookies-explained", "publisher": { "@type": "Organization", "name": "web.dev" } } ] }, { "@type": "BreadcrumbList", "@id": "https://webspecification.com/spec/security/cookie-attributes/#breadcrumb", "itemListElement": [ { "@type": "ListItem", "position": 1, "name": "Home", "item": "https://webspecification.com/" }, { "@type": "ListItem", "position": 2, "name": "Spec", "item": "https://webspecification.com/spec/" }, { "@type": "ListItem", "position": 3, "name": "Security", "item": "https://webspecification.com/spec/security/" }, { "@type": "ListItem", "position": 4, "name": "Cookie attributes — Secure, HttpOnly, SameSite", "item": "https://webspecification.com/spec/security/cookie-attributes/" } ] } ] }