Need answers

I don't know if I have a yeast infection or not? Every now and then I get frequent discharge sometimes it looks a little green then some days it's gone and fine, like I have good days then bad days when it happens or not. I haven't felt inching until now. I want to know how their caused?? So I can avoid getting it again in the future. I've been on birth control pills I don't know if that's a cause? I also wear pretty tight clothing which might not be so good? I've been really stressed lately. I don't think it has anything to do with being dirty or unhygienic because I'm a very clean person. The only time I can think of bacteria is during my period, or maybe sex? I'm also prone to bad UTIs. Can yeast infections be passed on to anyone else? (How do I get rid of it if I even have it??) Anything that works really good I can get from over the counter at drugstores?