Other articles

  • How Long Can Cookies Last?
  • What are the Most Important Cookie Laws?
  • Are All Cookies the Same?
  • How are Cookies used?
  • What is a Clear GIF?
  • How to Opt-Out of Cookies?
  • How to Manage Cookies?
  • What is Website Visitor Tracking?
  • What are Cookies?

Knowledge base

Menu

  • Pricing
  • Resources
    • Blog
    • Privacy laws
    • Knowledge base
    • Cookie Scanner
    • Privacy Policy Generator
    • System status
  • Features
    • Regulation compliance
    • GDPR (EU)
    • CCPA (California)
    • PIPEDA (Canada)
    • LGPD (Brasil)
    • KVKK (Turkey)
    • POPIA (South Africa)
    • The basics
    • 34 languages
    • User consents recording
    • Third-party cookie blocking
    • Geo targeting
    • Self-hosted code
    • Google Consent Mode v2
    • Automation
    • Automatic monthly scans
    • Automatic script blocking
    • Advanced reporting
    • Cookie Banner sharing
    • IAB TCF 2.2 integration
    • Google-certified CMP
  • For partners
    • Agencies
    • Affiliates
  • Support
    • Help Center
    • Integrations
    • Contact us
    • Feature request
    • Roadmap
    • Changelog
    • Profile
    • Billing
    • Membership
  • Sign in
  • Language switcher
  • Try now

How Long Can Cookies Last?

Cookies can last as long as their creator wants them to. The duration can be set when cookies are created. While session cookies are destroyed when the current browser window is closed, they can also persist for long after the page is closed. While every cookie has an expiry, this is just the date when the browser should no longer send the cookie to the server. In most cases, this means that after this date the browser will delete the cookie, but it depends on the clean up algorithms in the browser. It also depends on the browser running, as if the browser is not run, then it can’t clean up the cookie.

However, there are also persistent cookies that survive after you close your browser’s window. Persistent cookies can be used by websites to recognize your device in order to create personalized ads and optimize user experience for the next time you visit a website. Persistent cookies also create a convenient and faster website experience and enhances its performance. Such cookies have an expiration date issued to it by the webserver. This type of cookie is saved on your computer so when you close it and start it up again, the cookie is still there. For example, they are vital if you want to save your login details. However, once the expiration date is reached, persistent cookies are destroyed by the owner.

 
  • Terms of Service
  • Privacy Policy
  • Contact us
  • Sitemap
  • AI post generation

Copyright ©2025 Cookie Script


main version