A hypocrite means someone who tells or does something to another about his/her opinion, may defend it, but whenit comes to a situation where they are in it, they actually don't follow their original opinion.
For example, I tell you "You should eat Pizza. I love pizza and will eat it anywhere, it's good for you."
One day, you noticed I ordered pasta at pizza hut. When you saw that I didn't follow my original statement, I am by definition, a hypocrite.
The context and situation of the person you are trying to describe is important to determining word choice. The closest word I can think of that fits your definition is "martyr" given with what you said so far.
There are different ways of expressing a martyr, but for this one is one who may think she (or he) is sacrificing herself for the sake of benefiting others, but might not actually be true.