Viagra is a drug for erectile dysfunction that mostly works by bringing more blood to the penis, which helps men get and keep an erection. It can indirectly help you stay awake longer during sexual action by making it easier to keep an erection, but it doesn’t actually make ejaculation last longer. For some men, better sexual function may make them feel like they last longer, but Viagra’s main purpose is to help achieve and maintain an erection. If you have problems with ejaculating too soon or for too long, you might try other methods or treatments, like behavioral therapies, desensitizing creams, or certain exercises. It’s important to talk to a medical professional to figure out the best way to handle your specific needs and worries about sexual function.