Why could it hurt when I go pee after sex?

Urethral irritation. During vigorous sexual intercourse it is not uncommon to cause irritation near the urethra.
Many reasons. With penile-vaginal sex, there is rubbing of the shaft of the penis along the female urethra. This can cause irritation and some discomfort if there are issues with size, lubrication, vigourousness of sex, use of toys, manipulation with the finger(s), masturbation while having penile sex and any substances introduced during, before or after sex. It is probably just mechanical. If concerned c pc.