One of the Safari features I use frequently is “Close Other Tabs.”
The way it works is this: When you’ve got multiple tabs open, click on the “File” menu. If you hold down the Option key, “Close Tab” will switch to “Close Other Tabs,” as shown above. This is neat if you’ve opened up a ton of stuff and just wanna get rid of everything except the tab that you’re currently viewing!
And as you’ll note, the keyboard shortcut for this action is Option-Command-W.
You can also hold down Option and click on the “x” that’ll appear on your tab when you hover over it. A little tooltip will show up when you do so, warning you of what’s about to happen.
Finally, if you’re playing around and accidentally close a tab, you should know that you can press Command-Z (Edit > Undo Close Tab) to bring it back. I use that all of the time, too, but mostly because I’m just clumsy.