While it is a well-known fact that Xavier is Gambit officially replaced Xavier in that particular role in Magneto’s life.
When both Magneto and Professor X were introduced in X-Men #1 by Stan Lee and Jack Kirby, the two were portrayed as bitter enemies with completely different ideologies. Magneto believed that mutants were genetically superior to humans, and because of that, humans would fear mutants and work to exterminate them–so he was determined to launch a preemptive strike before that happened. Professor X, on the other hand, believed humans and mutants could live together in harmony, and the missions carried out by his X-Men perfectly reflected that vision. While their respective beliefs made Xavier and Magneto enemies, they weren’t always. Originally, the two were friends who used their mutant powers to help people, but over time, their opposite ideologies made friendship impossible–until eventually, both sides became radicalized by their own ideas for the future of mutantkind, with Magneto becoming a terrorist and Professor X militarizing mutant teenagers.
In Astonishing X-Men #1 by Scott Lobdell and Joe Madureira, readers are thrown into the world of the Age of Apocalypse, and this issue shows Magneto (the leader of the X-Men in this reality) meeting with his team to develop a plan of attack against Apocalypse. In this incarnation of Marvel’s Earth, there are a number of separate mutant teams that are loosely connected to the X-Men, and Magneto needs all of them to work together seamlessly if they are going to be successful in taking Apocalypse down. A leader of one of these off-shoot teams (the X-Ternals) is Gambit who showed up to the X-Men’s main headquarters to hear Magneto out and even work with the mutant leader despite their troubled past.
Gambit & Magneto Were Friends Who Became Enemies Just Like Erik & Charles
Before the events of this issue within the universe of the Age of Apocalypse, Gambit and Magneto were best friends just as Magneto and Charles were in Earth-616–and like Erik and Charles, Gambit and Magneto had a falling out. However, the falling out between Magneto and Gambit had nothing to do with differing ideologies, but instead was due to the fact that both men were in love with the same woman: Rogue. The relationship between Gambit and Rogue is well documented in Earth-616, but in the Age of Apocalypse, Rogue was truly in love with Magneto and the two of them had a son together after Rogue left Gambit for Erik. This romantic chain of events left Gambit and Magneto bitter enemies, ones who only work together if the fate of the entire world is at stake.
While the circumstances are completely different, this issue makes it a point to explicitly state that Gambit and Magneto used to be best friends–not ‘good’ friends, ‘best’ friends–before turning on each other, which is the same thing that happened between Professor X and Magneto. Since Charles Xavier was killed before he and Erik became rivals in this alternate timeline, that role in Magneto’s life was evidently ed to Gambit as he replaced Xavier as Magneto’s best X-Men frenemy.