Reoccurring uti and bacterial vaginosis

I am constantly getting uti's and bacterial vaginosis. I've gone to the doctor and everything for it, but I'm sick of having to go so much. It's embarrassing. I don't understand why I keep getting them, it's not like my boyfriend and I are dirty people.