Out of all the many enemies the X-Men have faced throughout the long history of the franchise, none have achieved as much cultural notoriety as Erik Lehnsherr, better known as Magneto. Famously played by Ian McKellen and Michael Fassbender in the previous live action films, Magneto has earned a place alongside the likes of Doctor Doom, Green Goblin, and Thanos as one of the most famous Marvel Comics villains in history.

But while Magneto is most often seen as a villain in pop culture, he’s a much more complex figure than your typical supervillain. Similar to other Marvel characters like Venom and Loki, Magneto has often walked the line between good and evil, and he’s spent just as much time aiding his heroic foils as he has fighting them. He may have started out as a villain, but there’s plenty of evidence to argue that Magneto is a hero — the question is, which is his true nature?

RELATED: Ant-Man 3 Director On Why He'd Direct A Nova Movie But Not X-Men

Magneto in the Movies

Professor X And Magneto May Be Back

When Ian McKellen’s Magneto first appears in the original 2000 X-Men movie, he naturally serves as the film’s antagonist. While he’s given some level of nuance thanks to his backstory as a Holocaust survivor, the sympathetic aspect of Magneto’s character isn’t explored in much depth. He’s mainly depicted as a typical evil mastermind, scheming to end humanity alongside his Brotherhood lackeys. In the 2003 sequel X2, Magneto initially joins forces with the X-Men in order to stop William Stryker from exterminating mutantkind. However, he ends up double-crossing the heroes, taking Stryker’s place as the film’s final villain. He soon resumes his main antagonist role in the series’ third entry, The Last Stand.

Magneto’s more human side wouldn’t truly be showcased in the movies until the 2012 prequel X-Men: First Class. The film explores Erik’s backstory in depth, from his traumatic childhood to his close bond with Charles Xavier. This younger Erik is shown to be a noble figure, albeit a vengeful one, and he initially fights loyally alongside the original X-Men. But in the end, his rage towards humanity wins out, and he ends the film by becoming the villainous Magneto featured in the previous films. The next film, Days of Future Past, sees both the past and present versions of Magneto joining the X-Men in the fight against the Sentinels — but like in X2, the younger Magneto later usurps the position of the movie’s big bad.

In 2016’s X-Men: Apocalypse, Magneto returns as a villain yet again when he’s recruited by the titular Apocalypse to be one of his Horsemen. However, he eventually turns against Apocalypse, ending the film as an uneasy ally to the X-Men — a role he continues into his final appearance in Dark Phoenix. Despite being widely reviled as one of the worst X-Men movies, Dark Phoenix has the dubious honor of being Magneto’s only film appearance to date in which he never serves as a villain. While both McKellen and Fassbender’s versions of Magneto have their sympathetic sides, they’re both portrayed as antagonists more often than not.

Magneto’s Complicated Comic History

Charles Xavier And Magneto In Marvel Comics

Much like in the movies, the Magneto of the comic books began as a pretty straightforward supervillain. Created by Stan Lee and Jack Kirby in 1963’s X-Men #1, Magneto began as a typical megalomaniac bent on world domination, in the same vein as Doctor Doom or Kang the Conqueror. However, when the legendary X-Men scribe Chris Claremont took over the title in 1975, he gradually began taking Magneto in a different direction. Under Claremont’s pen, Magneto sought to rule the world not out of lust for power, but due to an earnest desire to protect mutantkind from humanity.

1981’s Uncanny X-Men #150 proved to be the ultimate turning point in Magneto’s characterization. Not only does it crystalize the portrayal of Magneto as a sympathetic antagonist desiring peace through control, it also served as the initial reveal of Mageto’s backstory as a Holocaust survivor. The issue ends with Magneto nearly killing the X-Men’s new recruit Kitty Pryde — herself a Jewish teenager — by accident. Horrified by his actions, Magneto flees, sparing the X-Men. When he returns in the 1982 graphic novel God Loves, Man Kills, he forms an uneasy truce with his foes against William Stryker. But unlike in X2, Magneto never betrays the X-Men. And over the course of Claremont’s run, Magneto goes from the X-Men’s nemesis to one of their most loyal allies.

Indeed, Magneto spent most of the 80s as a member of the X-Men, even taking over the Xavier School for a time and mentoring the New Mutants in Charles’ absence. But when the 90s rolled around and Claremont left Marvel, later writers returned Magneto to his Silver Age roots as a ruthless tyrant. His descent back into villainy culminated in writer Grant Morrison’s celebrated run on New X-Men, which featured an aging, drug-addled Magneto devastating New York City as part of a genocidal plan to destroy humanity. This particularly nasty depiction of Magneto proved controversial among fans and creators alike, and Claremont soon returned to reveal that this Magneto was actually an impostor.

Since then, Magneto’s comic characterization has largely remained in line with Claremont’s take, and he’s never seen a lasting return to villainy since the Morrison run. In the 2010s, he even rejoined the X-Men, serving as Cyclops’ right-hand man in Kieron Gillen and Brian Michael Bendis’ respective runs on Uncanny X-Men. His status as an ally of the X-Men was cemented in the 2019 storyline House of X/Powers of X by writer Jonathan Hickman, which saw him finally end his feud with Professor X to help found the mutant nation of Krakoa. Most recently, he served as one of the main characters of Al Ewing’s widely acclaimed X-Men Red, in which he sacrifices his life to protect a mutant colony on Mars from the villainous Eternal called Uranos.

Erik Lehnsherr, Friend or Foe?

X-Men James McAvoy Magneto Professor X Michael Fassbender

It should be evident by now that no matter the medium, the story of Magneto is a long and convoluted one, filled with many twists and turns. He’s gone from evil to good and back again numerous times over the years, either due to natural character development or simply different creators having different ideas. As such, it’s difficult to definitively place him as either a pure hero or a pure villain. In that regard, he’s arguably Marvel’s greatest anti-hero, even more than Deadpool or the Punisher.

One could view Magneto as a villain first and foremost, since he’s always introduced in an antagonistic role before later undergoing a redemption arc. But at the same time, his story always seems to end with him as a stalwart ally of the X-Men — so in that sense, perhaps being a hero is his true nature. But as with all comic book characters, Magneto’s essence is ultimately malleable, dependent on what story a creator is trying to tell. But in the end, it doesn’t matter whether he’s fighting against the X-Men or alongside them. Either way, Magneto will always be one of Marvel’s most magnificent mutants.

MORE: X-Men: 5 Mutants Who Deserve to Be in Any Future Movies