Where is history stored with Safari 10.1 under OS10.11?

Everyone else is worried about clearing all records, but I spent more than a year setting up all the tabs that I want open for my work. After an institutionally mandated "upgrade", numerous programs failed to function and I got remote help that resolved most of those problems. Unfortunately, the remote Tech closed and re-opened Safari without doing a "Restore Previous Session" and then closed it, again. Short of painstakingly pouring over thousands of websites that I have visited over the past 12 - 18 months, perhaps I can find where Safari stored "Restore Last Session" history file I need within Time Machine. Any suggestions? I looked in ~Library//Caches/Metadata/Safari and found thousands of websites, but no "Restore Last Session"


First, close Safari, then enter Time Machine from /Users/YOURUSERNAME/Library/Safari/.

Next, restore the LastSession.plist file.

Then reopen Safari and then you can "Reopen All Windows from Last Session" in the History menu.


I think the thing you are looking for is called "Saved Application State". For Safari you can find it at /Users/YOURUSERNAME/Library/Saved Application State/com.apple.Safari.savedState.

If you close Safari, then copy the content of that folder (it should be three files I think) from a known good Time Machine backup into the current version of the folder, that should restore your tabs.