Tab Wrangler is a free Chrome extension which automatically closes tabs which haven't been accessed for a defined period of time.
Automatically closing anything may cause problems, but Tab Wrangler has plenty of built-in safeguards.
The extension won't close anything if you've only a few tabs open, for instance (less than 5, by default), and it won't close pinned tabs.
An auto-lock system protects tabs matching specific URL patterns. Spend a few minutes setting this up and you can make sure tabs on certain sites will never be closed.
And if you still lose something important, all auto-closed tabs are listed in the Tab Corral. Browse the list, select what you need, and it's immediately restored.
A configurable and effective way to free up tab space.