This question already has an answer here:
In the 50th anniversary special, after Gallifrey is saved this conversation happens:
WARRIOR: So I won't remember that I tried to save Gallifrey rather than burn it. I'll have to live with that.
DOCTOR 10: I won't remember either, so you might as well tell me.
DOCTOR: Tell you what?
DOCTOR 10: Where it is we're going that you don't want to talk about.
So I'm really confused. Why do the first 10 Doctors, William Hartnell, Patrick Troughton, Jon Pertwee, Tom Baker, Peter Davison, Colin Baker, Sylvester McCoy, Paul McGann, John Hurt, Christopher Eccleston, and David Tennant, have to forget the events of the episode, but Matt Smith's and Peter Capaldi's Doctors can be the only ones to remember? Every Doctor should remember saving Gallifrey but only Smith's and Capaldi's can remember which is weird.