Why Isn’t My Penis Getting Hard? Causes Explained

Difficulty getting or keeping an erection is one of the most common sexual health issues men face, and it almost always has an identifiable cause. About 13% of men in their 20s and 30s experience it, rising to 25% by the mid-40s and nearly half of men over 65. Whether the problem is occasional or persistent, something specific is driving it, and most causes are treatable.

How Erections Work

An erection depends on a chain reaction that starts in your brain and ends with blood filling the penis. When you’re aroused, nerve endings in the penis release a chemical signal called nitric oxide. That signal triggers the smooth muscle inside the penis to relax, which opens up the blood vessels and lets blood rush in. The blood fills two sponge-like chambers that run the length of the shaft, and as they expand, veins that normally drain blood get compressed, trapping it inside. That’s what creates firmness.

Anything that disrupts this chain, whether it’s nerve signaling, blood flow, hormone levels, or your mental state, can prevent an erection from happening or cause it to fade too quickly.

Blood Flow Problems Are the Most Common Cause

The arteries supplying the penis are relatively small compared to those feeding the heart or brain. That means they’re often the first blood vessels affected when something goes wrong with your cardiovascular system. Conditions like high blood pressure, high cholesterol, and diabetes damage the inner lining of blood vessels (a process called endothelial dysfunction), which prevents them from dilating properly when you’re aroused. Over time, cholesterol can build up into plaques that physically narrow the vessels and slow blood flow even further.

This is worth paying attention to. Research from the Mayo Clinic describes the penis as “one of the most powerful predictors we have, especially in young men, for heart attacks.” Because the penile arteries are smaller than coronary arteries, erection problems can show up years before a heart attack or stroke would. Persistent difficulty getting hard isn’t just a sexual issue. It can be an early cardiovascular warning sign.

Medications That Interfere With Erections

Several common prescription drugs can make it harder to get or stay erect. If your erection problems started around the same time you began a new medication, that’s a strong clue.

The biggest culprits include:

  • Blood pressure medications: Thiazide diuretics (water pills) are the most common cause, followed by beta-blockers. These reduce blood flow throughout the body, including to the penis.
  • Antidepressants and anti-anxiety drugs: SSRIs and other psychiatric medications frequently affect sexual function. This includes widely prescribed drugs in the fluoxetine and sertraline families, as well as benzodiazepines.
  • Opioid painkillers: Codeine, oxycodone, morphine, fentanyl, and methadone all suppress testosterone and interfere with arousal signals.
  • Antihistamines: Some over-the-counter allergy and heartburn medications, including diphenhydramine and cimetidine, can contribute.

If you suspect a medication is the problem, don’t stop taking it on your own. A doctor can often switch you to an alternative that’s less likely to cause this side effect.

Low Testosterone

Testosterone fuels sex drive and helps maintain the physical mechanics of an erection. Levels below 300 nanograms per deciliter are considered low, a condition called hypogonadism. When testosterone drops, you may notice reduced interest in sex, loss of morning erections, and difficulty getting hard even when you are aroused. Other signs include fatigue, loss of muscle mass, and mood changes.

Testosterone naturally declines with age, but low levels can also result from obesity, chronic illness, certain medications, or conditions affecting the pituitary gland or testes. A simple blood test can check your levels.

When the Cause Is Psychological

If you can get erections during sleep, when you wake up in the morning, or during masturbation but struggle during sex with a partner, the cause is likely psychological rather than physical. Performance anxiety is one of the most common triggers. Stress, depression, relationship conflict, and even watching too much pornography can all interfere with the mental side of arousal.

Psychological erection problems tend to come on suddenly and be situation-specific. Physical causes, by contrast, usually develop gradually and affect erections across all circumstances. Doctors use this distinction as one of the first steps in figuring out what’s going on. If no medical cause is found through blood tests and physical examination, a mental health professional can help identify and treat the underlying psychological factor.

Lifestyle Factors That Make It Worse

Smoking directly damages blood vessel walls and reduces blood flow to the penis. The good news is that quitting produces measurable results: some men notice improvement within weeks, and after three to six months of not smoking, many experience significant recovery in erectile function as the cells lining the blood vessels regenerate.

Obesity contributes through multiple pathways. Excess body fat increases inflammation, raises the risk of diabetes and heart disease, and can lower testosterone. Regular exercise improves cardiovascular health and blood flow, which directly supports stronger erections. A diet built around fruits, vegetables, whole grains, and lean proteins supports vascular health over time.

Heavy drinking is another common factor. Alcohol is a depressant that blunts nerve signaling and, when used chronically, lowers testosterone and damages the liver. Moderate or reduced alcohol intake often helps.

What Happens at the Doctor

Erection problems that persist for more than three months and consistently prevent satisfactory sex meet the clinical definition of erectile dysfunction. At that point, a medical evaluation is important both for treatment and to check for underlying health conditions.

A typical workup starts with your medical and sexual history, then moves to blood tests checking testosterone, blood sugar, cholesterol, thyroid function, and kidney and liver health. If results point to a blood flow problem, your doctor may order an ultrasound of the penis to see how blood moves through the vessels during an erection. In some cases, a nocturnal erection test (which monitors whether you get erections during sleep) helps clarify whether the root cause is physical or psychological.

Treatment Options

Oral medications that enhance blood flow to the penis are the most widely used first-line treatment. These drugs work by blocking the enzyme that breaks down the chemical signal responsible for keeping penile blood vessels dilated. They don’t create arousal on their own; you still need stimulation. But when the underlying issue is mild to moderate blood flow impairment, they’re effective for roughly half to two-thirds of men.

For men whose erection problems stem from low testosterone, hormone replacement can restore both sex drive and erectile function. Psychological causes respond well to therapy, particularly cognitive behavioral therapy and, in some cases, couples counseling. When anxiety is the main driver, even short-term therapy can break the cycle.

Lifestyle changes work both as standalone treatment for mild cases and as a way to boost the effectiveness of other treatments. Quitting smoking, losing weight, exercising regularly, cutting back on alcohol, and managing stress all target the same vascular and hormonal pathways that medications do. For some men, especially younger men with no underlying disease, these changes alone are enough to resolve the problem.