LDO - SOT223 - What's the Fourth pin for?
I can't find a picture of an SOT223, but here is a TO-220 which follows the same principle:



You can see how the tab and the middle pin are one and the same piece of metal.

As others have rightly mentioned, this is for heatsinking purposes, and is often required.  It is also used in some packages for high current connections, where you may have the tab as one connection, then 4 or 5 pins together for another connection (such as in >100A MOSFETs).