How to Make a Web Page Expire

by Bennett Gavrish

If users of your website will be entering very sensitive data, you may want to add a security feature to your pages to make them expire automatically. By adding the expiration meta tag to your pages, user data will not be retrievable when someone uses the back button on a browser. Instead, the page will indicate that the session has expired and needs to be restarted.

1

Open the HTML code of the web page you want to make expire.

2

Go to the "<head>" tags at the top of the HTML code.

3

Insert your cursor between the opening and closing "<head>" tags and add a new blank line.

4

Type "<META HTTP-EQUIV="Expires" CONTENT="-1">" between the head tags.

5

Save the HTML code and upload it to your active web server. Now, when a web browser loads the web page, it will recognize that the current session should expire when the user goes to another page.

Items you will need

References

About the Author

Bennett Gavrish is an I.T. professional who has been writing about computers, electronics and the Web since 2004. His work has appeared in the "Nashua Telegraph" and the "Daily Free Press" and on numerous websites. Gavrish received a bachelor's degree in journalism from Boston University.