Random swelling of foreskin area

it doesnt hurt and its only there during and after masturbation or sex

<img src='https://europe1.discourse-cdn.com/flex018/uploads/patient/upload-sm/upload-sm/133image

similar to what i have but mine isnt that severe, how did you upload photos?

Go to “Insert Image” icon in an active text box
Start your own Forum Discussion

Okay, what this can typically be is a Penile Lymphocele - yes they are linked to sex and masturbation, particularly rough or extended sex, or frequent masturbation
Easiest thing is to abstain from sex and masturbation for around 3 weeks or so until the fluid that causes this has drained naturally.
When you start up again make sure to take it real easy so you can check all s well again