Someone already beat me to the Get a Shotgun and the .45 penatrating walls rebuttal..
When you are 1/2 asleep and surprised or its dark, believe me you don't have time
to take aim with a pistol as well as you would like.. Nothing like at the range..
So, the Shotgun would be many peoples first recommendation for HOME protection.
Point and shoot with a wide range of hit potential so its forgiving on bad aim.
Loud as hell so it you do miss the dude is gonna haul ass regardless of PCP
Lower penetrating potential so you are less likely to kill the next door neighbors.
Very simple and reliable operation especially with a good pump gun like a Remington 870 you can get anywhere for $400 or even a Mossburg for less $
Use 00 buck 3" magnum shells.
I've read debate on the bird vs buck and read police reports of people hit with less than 00 at more than 20 ft that kept coming because the birdshot did not penetrate deep thru jackets etc.. Not to say it didn't hurt
but the stopping power of Magnum buck is awesome yet it won't go deep into walls.. It will tear them up but who cares about that at the time
Also important due to it being dark and you wanting to see where the end of the gun is pointing.. Get some stick on Magnetic Fiber Optic Glow sights:
http://www.hivizsights.com/content/category/category_1.asp
you are set
If you want a good low cost reliable carry weapon, the 1911 .45 auto is cheap but a bit big, or any of the good 9mm autos from glock or barretta, but get ready to pay high $ for the latter..