This Mac tip is provided by Mark Greentree and was originally posted on Mark’s blog – Everyday Mac Support. For more of Mark’s tips visit his site, follow him on Twitter, or browse his archive of posts here.
How to: Merge All Open Windows Into A Single Window In Safari
Do you use multiple windows in Safari?
Perhaps you clicked on a link that opened a new window, rather than a new tab.
If this is the case then you can simply navigate to Window > Merge All Windows, from the Menu Bar as shown below:

This option will take all open windows and add them as individual tabs in a single window.