why does my penis hurt when i pee

A urinary tract infection (UTI) or STI could be to blame for penile pain when urinating (STI). Get medical attention to rule out any serious health problems.