When men become sexually aroused, hormones, muscles, nerves, and blood vessels all work with one another to create an erection. Nerve signals, sent from the brain to the penis, stimulate muscles to relax. This, in turn, allows blood to flow to the tissue in the penis.

Once the blood fills the penis and an erection is achieved, the blood vessels to the penis close off so that the erection is maintained. Following sexual arousal, the blood vessels to the penis open up again, allowing the blood to leave.

At some point in a man’s life, he may have difficulty achieving or maintaining an erection. Erection problems occur when you can’t achieve or maintain an erection that’s firm enough to have sexual intercourse. Erection problems are also known as:

For most men, these problems occur occasionally and aren’t a serious issue. According to the Cleveland Clinic, there’s no cause for concern if erection problems occur up to 20 percent of the time.

However, if you’re unable to achieve an erection at least 50 percent of the time, you may have a health problem that requires medical attention.

The causes of ED can be physical, psychological, or a combination of the two.

Physical causes

Physical causes of erection problems are more common in older men. They occur because of disorders that can affect the nerves and blood vessels responsible for causing an erection.

Physical causes include medical conditions such as:

Other physical causes include:

Psychological causes

Emotional issues can distract a man of any age from becoming aroused, and include:

  • worry over not being able to achieve or maintain an erection
  • prolonged emotional distress related to economic, professional, or social issues
  • relationship conflicts
  • depression

Men ages 20 to 30 years old may experience ED as well. The numbers suggest that ED in young men occurs more often than previously reported.

In 2013, The Journal of Sexual Medicine reported that 26 percent of men ages 17 to 40 years old experience trouble having an erection. These cases range from moderate to severe.

Research says erection problems in young men have more to do with their lifestyle and mental health than with any physical problems. Younger men were found to use more tobacco, alcohol, and drugs than older men.

Some studies suggest that erection problems in young men most often stem from anxiety or depression.

Tests that your doctor may order to determine the cause of your erection problems include a:

Once your doctor determines the cause of your erection problem, they’ll provide appropriate treatment.

Severity of ED is often graded on a three-point scale: mild, moderate, and severe. Severe ED is also known as complete ED. The first step in treating your ED is identifying where you fall on this scale.

Once a cause is identified and your doctor knows how severe your ED is, it becomes easy to treat.

Options for treating erection problems may include:

Lifestyle changes

Many of the physical causes of erection problems are related to lifestyle choices. You may want to consider the following lifestyle changes:

If lifestyle changes don’t reduce your symptoms, contact your doctor to determine the root cause of your erection problems.

Your doctor will examine your penis, rectum, and prostate as well as the function of your nervous system. They’ll also ask you when your symptoms began and whether you have any current health problems.

The complications that come with erection problems are significant and can affect your quality of life. If you experience erection problems, you may also experience:

  • stress or anxiety
  • low self-esteem
  • relationship problems
  • dissatisfaction with your sex life

If you develop erection problems that get worse over time, you should call your doctor. You should also call your doctor or schedule an appointment if erection problems:

  • develop or worsen after injury or prostate surgery
  • occur alongside lower back pain or stomach pain
  • you believe a new medication is causing a problem

You should still take your medication, even if you think it’s causing your erection problems, until your doctor says otherwise.

Healthy lifestyle behaviors, such as getting regular exercise and eating a healthy diet, can help prevent ED.

ED is caused by a lack of blood flow, so circulatory health is key. A common way to improve blood flow is through exercise. Some cardio-based exercises to try include:

Avoiding unhealthy fats, excess sugar, and large amounts of salt is important as well.

Chronic health conditions, such as diabetes and heart disease, can lead to erection problems. Another possible cause is the prescription medications used to treat those conditions. If you have a chronic condition, ask your doctor which prevention methods are most appropriate.

Treatment for substance abuse may also help you avoid erection problems caused by issues with alcohol or drugs. Mental health treatment may help you avoid erection problems caused by stress or psychological issues.

Erection problems are common, and they can happen to men of all ages. They typically involve issues with at least one of the phases of male sexual response:

Be aware of the warning signs, and visit your doctor if erection problems start to occur more frequently. Although erection problems can be difficult to experience, effective treatments are available.