For IE
Click on the "Tools" menu, selecting "Internet Options'... On the "Internet Options" multi-tabbed dialog box that appears... near the bottom of the dialog box... you should see this prompt:
"Days to keep pages in history:"
If you want your history pages to expire after seven days, place a 7 in the box and press OK... If you want pages to expire sooner... enter a smaller number... If you want pages to expire later... enter a larger number.
Firefox allows you to set the browser to clear all private data...passwords/browser history etc on closing the browser window...it's a much safer browser to use as well.