Skip to content
Advertisement

Reading cookie expiration date

Is it possible to read cookie expiration date using JavaScript?

If yes, how? If not, is there a source I can look at?

Advertisement

Answer

It is not possible to get the expiration date of a cookie through Javascript; only key-value pairs are exposed through document.cookie.

Advertisement