Although most men experience episodes of erectile dysfunction from time to time, you can take these steps to decrease the likelihood of occurrences:
Work with your doctor to manage conditions that can lead to erectile dysfunction, such as diabetes and heart disease.
Limit or avoid the use of alcohol.
Avoid illegal drugs such as marijuana.
Get enough sleep.
Get help for anxiety or depression.
See your doctor for regular checkups and medical screening tests.