When your child gets the measles vaccine, their immune system makes protective virus-fighting antibodies against the weakened vaccine virus. 

Measles vaccine protects your child from wild-type measles because if your child has been vaccinated and then is exposed to someone with measles, his/her body remembers how to fight off the wild-type virus. That is because the vaccine has trained his/her immune system to fight against the measles virus.