The healthier your cardiovascular system, the healthier your erection.
Quick anatomy review for those who weren’t paying attention in health class (or for those for whom it’s been a while since you’ve been in a health class). Your erection is caused by a rush of blood being trapped in your corpora cavernosa. The blood has to get there somehow, and of course, it’s through your arteries, or the vascular part of the cardiovascular system (cardio being for your heart).
At least one study showed that erectile dysfunction is often an early indicator of cardiovascular disease, and if you have ED, you should ask your doctor (you do go to the doctor, don’t you?) to screen you for heart and vascular issues.