Viagra is a miracle pill, right? Actually, it is suprising how often Viagra and the other PDE5 Inhibitors do not work for men with erectile dysfunction. Many guys are left asking, "Why doesn't Viagra work for me?"
Just how common is this issue? PDE5 Inhibitors, such as Viagra, Levitra and/or Cialis, are unsuccessful in about a fourth of all men with erectile dysfunction. Furthermore, in certain at-risk subpopulations, there is an even greater chance for failure. For example, only about half of all diabetics are able to use one of these medications successfully. 
So why, pray tell, would a powerful drug such as Viagra and Cialis, not work? Well, the research has uncovered some interesting and not-necessarily-obvious reasons for this stressful phenomenon:
1. Resistance. You can actually become resistant to PDE5 Inhibitors over time.  Of course, that means you must up the dosage to get the same effect and this is problematic because Viagra, Cialis and Levitra have so many side effects. See my link on Viagra and Cialis Resistance for more details. (In addition, you may want to read on The Side Effects of PDE5 Inhibitors and The Dangers of Cialis for more information.)
2. Low Testosterone/Venous Leakage. Some guys actually have atrophy of various peniles tissues, including nerve, connective and muscular. This most often occurs in a low testosterone environment and I have covered in detail in my link on Venous Leakage. This can usually be greatly improved through Testosterone Therapy.
3. Lack of Baseline Nitric Oxide. One major reason, and I cover solutions for this condition in my link on Viagra Failure, is the lack of baseline nitric oxide. Many men with endothelial dysfunction simply do not supply enough raw materials into this biochemical pathway to make up for the age-related loss in this compound, a term called "nitric oxide insufficiency." You can't "squeeze blood out of a turnip" as they say.
4. Psychology (Fear, Anxiety, etc.). Some guys have normal erectile strength, yet have erectile dysfunction during intercourse. This is termed psychogenic (psychological) erectile dysfunction and can be very difficult to overcome. Interestingly enough, Viagra and other PDE5 Inhibitors can be used as partial or even complete treatment as I document in my link on Psychogenic Erectile Dysfunction. However, for those who experience failure, obviosly no amount of these medications will help.
5. Major Medical. Certain major medical conditions such as prostate procedures, pelvic surgeries, back injuries and advanced cardiovascular disease can negate all normal drug-related attempts to acheive an erection.
1) Current Vascular Pharmacology, 2006, 4:89-93, "The Management of Phosphodiesterase-5 (PDE5) Inhibitor Failure"
2) J Urol, 2001 Sep, 166(3):927-31, "Long-term efficacy of sildenafil and tachyphylaxis effect"