Self Defense Load - 12 Gauge
If you expect to be dealing with a home invasion, then figure as SM said, #4, 00, or Slugs. That kind of action is almost always under 20 feet, more commonly right up close, so any discussion about patterning, etc. will be moot. You are going to be in the ultimate point and pray mode if this ever happens to you.
Assuming you hear the miscreant coming, having crashed through your door, in an average house the biggest problem will be to maintain your own calm so you can act at all rationally in the few seconds this encounter will consume. Sad fact is most times the homeowner is caught sleeping by a 1000% alert intruder with maximum motivation to do bad things. Not a pretty sight, after.
Best real life solution in a hell of a big dog who'll make enough noise and delay the bad guy long enough for you to wake up and get moving.