Re-evalue why you think she is your friend.
My friend is mean to me sometimes she tells me to shut up and talks about how my crush flirts with her!She knows that i don't like it when she does that! My crush likes her! But she sometimes says she hates him?What should i do?
Talk to her and ask her why she's being mean to you. If she keeps being mean then think, is she REALLY your friend? If you feel like telling her more straightforward than a nice little talk (trust me so do I sometimes) then when she says "Shut up" say "Sorry but I was just trying to make a conversation". When she talks about your crush flirting with her say that you feel bad enough without her rubbing it in your face. Except maybe a little nicer than that.
Sometimes girls can be horrible! Just tell her straight you don't like it and maybe she'll stop. If she doesn't, ask yourself if she really deserves to be your friend. There are somethings that have to be said in order to solve a problem, if you don't do the action, the result (being her quitting the meanness) will most likely not happen.
She wants the attention and you should not be her friend anymore if she continues this tirad of saying her crush likes her. You do not need her as a friend and I had that happen to my friend when a girl says her boyfriend flirted with her when really he did not. He was just joking around. My friend decided to not talk to her anymore and you shall do the same.
I would defiantly just back away from this friend.. That doesn't mean that you can't be friends with her just distance Yourself. Don't tell her all of you secrets and maybe just look for other friends who don't treat you this way:)) don't worry all girls go through this it going to be ok:D
The best thing to do is talk to her because I don't think you wanna break that friendship that you two have.
She's a b*tch, tell her youre not her friend anymore.