Tadalafil works by increasing blood flow to the penis during sexual stimulation. It achieves this by inhibiting the enzyme phosphodiesterase type 5 (PDE5), which is responsible for the degradation of cyclic guanosine monophosphate (cGMP) in the corpus cavernosum of the penis. By inhibiting PDE5, tadalafil increases levels of cGMP, leading to smooth muscle relaxation and vasodilation in the penile blood vessels, allowing more blood to flow into the penis and resulting in an erection.