Greasy Fork is available in English.
Export cookies in Netscape, JSON, or header format for curl, wget, yt-dlp — replaces Get cookies.txt LOCALLY
☕ If you find this tool helpful & would like to support its maintenance, please consider leaving a tip on:
Thank you! :-)
🖼 For a quick impression of this script, refer to the screenshots at the bottom.
Exports browser cookies in Netscape, JSON, or header format — compatible with curl, wget, yt-dlp, aria2, HTTPie, and more.
Replaces Get cookies.txt LOCALLY — no browser extension needed, works entirely through your userscript manager.
Downloading authenticated content requires valid cookies. Dedicated cookie extensions exist, but they add another icon to your toolbar, another permission to manage, and another update to track. This script uses your userscript manager's built-in GM_cookie API — no separate extension needed.
| Action | Result |
|---|---|
| VM/TM menu → Export Cookies | Export cookies for current site |
| VM/TM menu → Export All Cookies | Export cookies for all sites |
| VM/TM menu → Format: name (click to change) | Cycle through Netscape, JSON, header |
The export includes auth cookies by default. To include HttpOnly cookies:
Violentmonkey (Beta v2.35.1+):
Tampermonkey:
curl -b www.youtube.com_cookies.txt "https://example.com"
wget --load-cookies=www.youtube.com_cookies.txt "https://example.com"
yt-dlp --cookies www.youtube.com_cookies.txt "https://youtube.com/watch?v=..."
aria2c --load-cookies=www.youtube.com_cookies.txt "https://example.com"
http -b @www.youtube.com_cookies.txt "https://example.com"
domain then empty details if the URL-scoped query fails.example.com_cookies.txt.| Manager | Status |
|---|---|
| Tampermonkey | ✅ Full support |
| Violentmonkey | ✅ v2.35.1+ (enable HttpOnly per above) |
| Greasemonkey | ❌ GM_cookie not supported |
The exported file works with any tool that accepts Netscape cookie files — notably curl, wget, yt-dlp, aria2, and HTTPie. This is the same format used by the original Netscape browser and adopted by curl; it remains the standard for passing browser cookies to command-line HTTP tools.
No configuration required. For full auth cookie export including HttpOnly cookies, enable cookie access in your manager's settings (see above).