The medication , commonly known as Viagra, is a regulated treatment largely used to manage impotence in males . Developed initially for heart conditions , its unexpected side effects relating to the widening of blood vessels led to its new application as an reliable solution for sexual health issues . It works by enhancing blood flow to the private