Sildenafil, sold under the brand name Viagra among others, is a medication used to treat erectile dysfunction and pulmonary arterial hypertension. It is unclear if it is effective for treating sexual dysfunction in women. It is taken by mouth or injection into a vein. Onset is typically within 20 minutes and lasts for about 2 hours.