Common causes of erectile dysfunction (ED) include stress, anxiety, depression, diabetes, heart disease, obesity, smoking, excessive alcohol consumption, and certain medications. Potential treatments involve lifestyle changes like exercising, quitting smoking, and reducing alcohol intake. Medications such as sildenafil (Viagra) and tadalafil (Cialis) can be prescribed.