HTTP Cookie Builder
Generate a Set-Cookie header with all attributes — Path, Domain, Max-Age, Expires, Secure, HttpOnly, and SameSite.
Set-Cookie header
Set-Cookie: session=abc123; Path=/; HttpOnly; SameSite=LaxSet-Cookie header attributes explained
The Set-Cookie HTTP response header stores a small piece of data in the browser. Key attributes: HttpOnly prevents JavaScript from reading the cookie (mitigates XSS); Secure ensures it is only sent over HTTPS; SameSite=Lax or Strict protects against CSRF; and Max-Age sets an expiry in seconds relative to the current time (preferred over Expires).
For related security headers, see the HTTP Security Header Generator or the CSP Generator.
Private & free — this tool runs entirely in your browser.
Recommended: Namecheap — Register a domain for your next project — from $1.98/yr.affiliate
Related Web & SEO tools
Meta Tag Generator
Build SEO title, description, and viewport meta tags.
Open Graph Generator
Generate Open Graph and Twitter Card meta tags.
Robots.txt Generator
Build a robots.txt file with per-bot rules. Block AI crawlers, set crawl delays, define sitemaps.
UTM Campaign URL Builder
Append UTM parameters to build trackable campaign URLs.
Hreflang Tag Generator
Generate hreflang link tags for multilingual SEO.
Sitemap XML Generator
Build an XML sitemap from a list of URLs.
SERP Snippet Preview
Preview how your page title and meta description appear in Google search.
Meta Tag Analyzer
Paste a page's HTML head to audit its title, meta, and social tags.