Cookie Max-Age to Expires Converter
Convert a cookie Max-Age in seconds into the Expires date your server sends in a Set-Cookie header, in HTTP date and ISO 8601 formats. Optionally set the start time; it defaults to now.
1 Fill in the boxes
2 Your answer
Your answer shows here as you type.
How to use the Cookie Max-Age to Expires Converter
- Enter the Max-Age in seconds, for example 3600 for one hour or 86400 for one day.
- Optionally enter a start time in UTC, such as 2026-01-01T00:00:00Z. Leave it empty to start from now.
- Copy the HTTP date into the Expires attribute of your Set-Cookie header.
Frequently asked questions
What is the difference between Max-Age and Expires on a cookie?
Max-Age is a number of seconds from when the cookie is set. Expires is an absolute date in HTTP date format, such as Thu, 01 Jan 2026 01:00:00 GMT. When both are present, browsers use Max-Age.
How do I convert seconds to an Expires date?
Add the Max-Age to the current time in UTC, then format the result as an HTTP date with the day, month, year, time and GMT. For example, 3600 seconds from 00:00 UTC on 1 January 2026 is 01:00 GMT.
What does a Max-Age of 0 or less do?
A Max-Age of zero or less tells the browser to delete the cookie immediately.
Wrote something with AI? Slop Monkey rewrites it so it sounds like you, and keeps your facts.