Set-Cookie Header Parser

JSON →
library 3.1.0 ·javascript
verified May 27, 2026

set-cookie-parser is a JavaScript/TypeScript library designed to parse `Set-Cookie` HTTP response headers into structured JavaScript objects. It currently stands at stable version 3.1.0 and is actively maintained, with a healthy release cadence and recent updates. The library is highly versatile, accepting various inputs including single header strings, arrays of header strings, Node.js `http.ServerResponse` objects, and `fetch()` `Response` objects. A key differentiator is its ability to return either an array of cookie objects or a map where cookie names are keys, depending on configuration. Each parsed cookie object provides a comprehensive set of attributes, including `name`, `value`, `path`, `domain`, `expires` (as `Date` objects), `maxAge`, `secure`, `httpOnly`, `sameSite`, and `partitioned`. It ships with built-in TypeScript types, ensuring robust type checking and improved developer experience in modern TypeScript projects.

total hits 13
actors 5 distinct systems
last hit 20h ago human
GPTBot
5
Script
1
ClaudeBot
1
Search engines
1
Humans
2

top countries 🇺🇸 United States · 🇨🇦 Canada · 🇩🇪 Germany · 🇪🇸 Spain · TH