Granted, there are some other great handguns out there, but if you're buying a handgun — perhaps your first, perhaps your only — the Glock 19 is a stand-out choice. It's small enough to carry, and big enough to use in a fight.
First, Glock perfected the modern striker-fired pistol. Others had tried polymer bits and pieces, and some had tried striker-fired weapons, some had introduced "high-capacity" handguns, and some had even combined all three into the same gun before Glock did (I'm thinking of the H&K VP-70Z, a truly awful weapon). When Glock showed the world the Glock 17 (also in 9mm, the full-size version of the Glock 19), there must have been a lot of gun designers who collectively smacked their foreheads with the palms of their hands.
Here's my take on the Glock 19 and some of its competitors, including the externally-similar Smith & Wesson M&P 9, the Springfield Armory XD, and the Ruger SR9 and Kahr PM9 (not pictured). Perhaps I should mention that I am not sponsored by Glock, nor reimbursed by it in any way.
This is more or less personal, but I would rather buy from the innovator than from the copier, all things being equal. That puts the Glock in the lead right off the bat, especially compared to the Ruger, which seems to be the closest in terms of internal design.
Glocks have three internal safeties that — as long as you follow rules for safely handling your weapon — prevent unintended discharges. These safeties engage and disengage automatically as part of the normal operation of the weapon, so you don't need to push any special levers or buttons to get the gun to run. Others have copied this approach, but Glocks are really dialed in on this. This makes it very easy to learn to manipulate a Glock safely and skillfully, because the gun itself makes few demands on you. As a perhaps extreme example, compare the operation of the Glock 19 with that of the Beretta 9. This is not to say that the Beretta is not a fine piece of machinery, but it appears to have been designed by a committee, with all the negative connotations that implies.
Look at the photo above of the three guns. Each of the three has the magazine in, so from the outside, you don't know if any of them is loaded, empty, safe, or dangerous … except one: The Glock. Because of the internal design of the Glock trigger, when the weapon is empty you can "trip" the trigger and it will stay in the rearward position, as shown in the photo. In this condition, there is no way this gun is going to fire, no matter how many rounds may be in the magazine. In this condition, if there is a round in the chamber it is a dud (that is, it did not fire when the trigger was pulled; a fairly rare occurrence), so the chances are that the chamber is empty, too. For me, this is a huge plus in the safety column for the Glock. The M&P and the XD have different trigger systems, which you may either love or hate, but the fact of the matter is you cannot tell at a glance that either of those guns is safe.
The trigger pull on the Glock is the same each time, first shot to last. On the Glock, the trigger pull is lighter (with shorter travel) than that of a double-action revolver and heavier (with longer trigger pull) than that of a single-action 1911. Normally, a heavier trigger means reduced accuracy, but you don't want a hair trigger in a tense situation because you could accidentally fire your weapon at the wrong time or in the wrong direction. Handguns that do not have the same trigger pull from shot to shot include the Beretta 9 and the Sig Sauer P-2xx (among others). On these guns, the trigger pull on the first shot is similar to that of a double-action revolver, while follow-up shots have the trigger pull of a single-action 1911; one more thing to learn to master in what may be the most difficult situation you ever face.
Glocks have a reputation for reliability and ease of use. These are exactly the qualities you want in a defensive handgun.
In terms of features, Glocks have everything you need in a defensive handgun, and nothing you don't. This too is exactly what you need in a defensive handgun.
Taking apart the Glock for routine cleaning could not be easier. Also, Glock pistols have relatively few parts, which also makes disassembly and cleaning that much easier.
There is a wide range of Glock models available, so if for some reason the Glock 19 isn't for you, there will be another one that is. Also, with the exception of the full-size .45 caliber Glock 21, Glocks in other calibers feel very similar in your hand, making it trivial to transition from one to another. On a side note, if you like your Glock in the 9mm, .40 caliber, etc., and you decide you want a .45, check out the Glock 21SF. This is the short frame version of the standard full-size Glock 21, so the fit and feel will be more like that of the smaller-caliber Glocks.
If you ever get the urge to personalize (AKA modify) your Glock, there are aftermarket suppliers who make everything from mild to wild for the Glock. The Glock ecosystem is astonishing in its depth and breadth.
If you spend any time handgun shopping, you’ll soon discover that in addition to the choices mentioned above there are many, many others, and other configurations, too. You could probably drive yourself nuts trying to evaluate all the handguns and all the handgun features. This is especially true if you don't have access to loaner guns to try out beforehand, as after doing all your research you'll have to buy your guns to see if they work as well for you as they seem as though they will on paper.
Obviously, nothing man-made is perfect, but if you're looking for a defensive handgun the Glock 19 is pretty near ideal, and unless you are at one of the extremes in body/hand size, there's nothing so wrong with it that a trip to Front Sight won’t provide a work-around, if not a cure.
This is my opinion, but of course you are entitled to your own.