Why when I masturbate I always get some kind of infection?

Should not happen. Wash your hands and your "nether regions". Do not insert anything into your urethra. Make sure vibrator or dildo is perfectly clean. It is also best to empty your bladder afterwards.
Masterbation infecti. I suppose you are a female with a namenellie.You are introducing germs in your vagina.To prevent that you should trim your nails, wash your hands and keep the pelvic area including labia, and vagina washed with soap and water.If you use any sex toys, have them cleaned with soap ang water.That will make the episodes of infection rare.Remember personal hygiene, if u still get it see your gynocologist.