All Potter fans know the story: Harry glimpses Snape’s “Worst Memory” in fifth year and discovers that his father was not the great guy that any orphaned child would prefer to envision. His dad was a horrible bully who tormented fellow classmates and had a towering ego to match. When Harry asks his father’s two best friends from childhood—Sirius Black and Remus Lupin—about said memory, they mollify him by saying that James was just a dumb kid at that point in time, and that he got better because he wanted Harry’s mother to fall for him. As romances go, it’s not exactly an uplifting story.

But if we track the little we know about James Potter’s development, it seems likely that someone else was at the center of his turnaround. After all, it wasn’t Lily Evans who ran away from home and straight to the Potters’ one night….

Now, before we even get into this—there are plenty of fans who prefer to think that James Potter didn’t really change at all as he got older. And it’s understandable that his recalibration might be hard to buy because what he does to Snape in that memory is very hard to swallow. The idea that a teenager who acts in such a callous manner is capable of becoming a decent person is at odds with much of what we’re told socially. The going wisdom is generally—bad kids stay bad, good kids become useful adults. “Don’t make friends with boys like Billy, or you’ll come to a nasty end” and the like. What paves the way toward emotional development in young people? Well, at this point, we’re pretty sure that the major contributor to kindness in kids is teaching them empathy. The more we can relate to someone, the kinder we’re likely to be to them.

We know James Potter was not entirely lacking in empathy as a boy, and we know that because of his desire to help Remus Lupin (who is a werewolf) deal with full moons. Sure, there was an element of rule-breaking to it—creating the Marauder’s Map, becoming illegal Animagi—but at the end of the day, simple rule-breaking and rebellion could have been achieved even if he hadn’t been friends with a werewolf. So James cared about his friend Remus, and was therefore capable of caring about others. With that in mind, it was not impossible (or even improbable) that James Potter would eventually cultivate enough empathy to become a pretty good dude. I’m putting it lightly here because Rowling as an author never puts stock in character absolutes; there is practically no one in the Potter series who is purely good or evil, no matter how far they tip the scale in one direction or another. So James Potter didn’t become a saint—he became a nice man with blind spots, a kind person who was prone to bouts of ego and petulance because he’s human and we’re never angelic all the time.

Why am I adamant about this? Because there is no point in making an issue of James’ development if it never truly happened, and the books do make issue of it. In addition, James Potter manages to gain the affections of Lily Evans, and she is as close to sainthood as the Potter canon allows mere mortals to get. The sparkling, sharp, talented, lovely Lily Evans didn’t get duped into liking this guy. He had to earn her affection by proving his merit.

That said, the whole “he got nice to make Awesome Lady fall in love with him” is rarely a storyline that rings true… probably because it sounds like a bad rom-com plot. Perhaps James made more of an effort for Lily’s sake, but a remarkable about-face like his requires substantial and deeply personal motivation. James Potter may know Lily Evans, but they don’t seem particularly close at the point where he initially tries to win her affections. It is far more likely that he would change for the sake of someone or something else, and that his actions were simply misinterpreted. Remember who tells Harry that James got it together to become a more suitable prospect to Ms. Evans—his two closest friends. It’s relevant that this is secondhand information, not the sort given to us by the narrative. It means that Sirius and Remus might have it slanted.

Then what caused this massive transformation? Theory Time! I’m going to put forth a timeline below to put some things in perspective….

First Year at Hogwarts: The Marauders start school, along with Lily and Snape.

The Marauders start school, along with Lily and Snape. Between First and Second Year at Hogwarts: James, Sirius, and Peter figure out that Remus is a werewolf. They start putting in work to become Animagi.

James, Sirius, and Peter figure out that Remus is a werewolf. They start putting in work to become Animagi. Fifth Year: The Marauders succeed in becoming Animagi and start accompanying Remus on full moon jaunts. Sirius pulls a “prank” on Snape, sending him into the Whomping Willow to encounter Remus in werewolf form. James hears about what Sirius has done and goes after Snape, pulling him out of harm’s way.*

The Marauders succeed in becoming Animagi and start accompanying Remus on full moon jaunts. Sirius pulls a “prank” on Snape, sending him into the Whomping Willow to encounter Remus in werewolf form. James hears about what Sirius has done and goes after Snape, pulling him out of harm’s way.* End of Fifth Year: (post-exams) What is referred to as “Snape’s Worst Memory”—James and Sirius brutally harass Snape in front of other students. Snape calls Lily a Mudblood, Lily tells James that she would never date him because he’s an egotistical jerk. Later, Snape tries to apologize for calling Lily a Mudblood, but she’s not interested; she ends their friendship due to his association with Death Eaters.

(post-exams) What is referred to as “Snape’s Worst Memory”—James and Sirius brutally harass Snape in front of other students. Snape calls Lily a Mudblood, Lily tells James that she would never date him because he’s an egotistical jerk. Later, Snape tries to apologize for calling Lily a Mudblood, but she’s not interested; she ends their friendship due to his association with Death Eaters. Summer Between Fifth and Sixth Year: Sirius runs away to the Potters, leaving his family behind.**

Sirius runs away to the Potters, leaving his family behind.** Seventh Year: James becomes Head Boy and seems nice enough now for Lily to start dating him. *Before Deathly Hallows was released, it was widely assumed by fandom that the “Willow Incident” took place in Sixth Year rather than Fifth. (It was already known that it took place when Sirius was sixteen, which meant that it could have been either year.) It’s eventual placement before “Snape’s Worst Memory” is incredibly awkward, if only because it seems unlikely that James could get away with abusing Snape publicly mere months after he was almost killed due to his group of friends and their activities. In addition, there are errors in the text regarding the memory; it is stated twice (in the narrative and in dialogue) that James is fifteen during the bullying incident, when he should be sixteen—his birthday is on March 27, 1960 and Snape’s Worst Memory occurred in June of 1976. **This is conjecture on my part. We know that Sirius ran away from his family when he was about sixteen, putting this event during a holiday between Fifth and Sixth Year. It seems likely to me that it would occur during a summer break, as that allows enough time for Sirius’ issues with his family to come to a head.

At first glance, it’s not surprising that someone would assume James changed for Lily. The progression looks simple; James straightened up his act during Sixth Year, after Lily told him that he was disgusting and conceited. By Seventh Year, he’s emerged as dating material. But here’s the thing—there was someone else in James’ life who clearly demanded a lot of his time and attention, and that person was in the process of a major upheaval right around the time that James decided to make these broad changes. It was Sirius.

So let’s look at that timeline again. In Fifth Year, Sirius decides to play a “prank” on Snape, telling him to head down into the Whomping Willow to find out where Remus has been disappearing off to every month. This little joke could have easily cost Snape his life. James recognizes this, and stops Snape before he is hurt. Dumbledore swears Snape to secrecy about Remus’ condition, but it’s likely that the Marauders are worried about whether or not he’ll keep his promise. (Which makes sense, given that he apparently has spouted the werewolf “theory” to Lily following the incident.) More to the point, James Potter’s best friend almost got another one of their friends to unknowingly commit murder, and thought of that as a prank. Regardless of how much James hated Snape, that had to have been a disturbing turn to him, especially given the damage it would have done to Remus. (James clearly feels an amount of responsibility for Remus given their activities as students and his choice to support Remus financially once they’re out of school.)

Snape’s Worst Memory occurs for a very specific reason—James doesn’t start antagonizing Snape until Sirius says that he’s bored. He’s pleased enough to get Lily’s attention over it, but the initial impulse is to keep his best friend busy. Which means that keeping Sirius occupied is also something that James feels responsible for. Aside from the fact that James and Severus are mortal enemies, might there be an additional reason why James thinks it’s so important to distract Sirius Black from boredom?

Well, their tests are over. Which means that in a few days time, Sirius will be going home to Number 12 Grimmauld Place.

Presuming that the series of events is (and we have no canonical guarantee of this)—Whomping Willow Incident, Snape’s Worst Memory, Sirius runs away from home—we’ve got a pretty clear arc of how Sirius’ home life affected his overall state. And seeing as James Potter is Sirius Black’s very best friend in the whole wide world, it’s likely that he had some idea of how bad it was getting. But James isn’t emotionally mature enough yet to realize that distracting Sirius by abusing their classmate isn’t a helpful way of bucking up a friend right before he goes home to his own abusive situation.

Soon after, Sirius runs away from home and takes refuge with James and his family. While the Potters may have spoiled their only son rotten, we know from Sirius that they were kind and supportive of his own plight in a way that was ultimately beneficial; he was able to get on his feet after staying with them for some time, and they let him know that he was always welcome in their home for supper. James would have seen how his parents reacted to Sirius’ choices, the way they protected him and provided the net that he required. And just perhaps, James might have realized that he needed to be that sort of person for Sirius, too. It might not seem like a large event for the attention it gets in the narrative, but the choice to separate from one’s family is a traumatic thing. Having a close friend who made such a decision would be a sobering event for anyone. In fact, it might make someone who has an untold amount of privilege consider what life would be like without it.

The first war against Voldemort was getting worse every day while the Marauders were at school, and now James comes into hard contact with the reality of that world; Sirius can’t abide his abusive family and what they stand for; Remus will probably be unable to find a job after they graduate in the current climate; who knows what could happen to Peter, who’s always looking to his friends for protection. And then there’s the girl he fancies, who happens to be exactly what Voldemort is railing against—Muggle-born wizards. If James is going to be any use to anyone, he has to step up and do it fast.

Sixth Year is when James Potter gets it together. And because Lily finally notices him in Seventh Year and starts dating him, his friends assume she must be the reason. Oh look, James got his act straight and the girl of his dreams finally deems him worthwhile. That must be why he worked so hard last year. It makes sense to them, and prevents James from having to admit what really turned his head—the sudden understanding that his friends were going to need him, and soon. A revelation that began because Sirius Black ran away from home, and James came to understand the damage done by his family. He had a moment to reflect and see just how lucky he was.

Of course, this is entirely speculation. But the cause-and-effect here have a drive and a causality that come from a real emotional place, instead of this muddy I-got-better-to-impress-a-girl thing. That would be fine if the change had been slight, but for all the reader is led to believe, this is the point where James Potter decides to become a more compassionate, mature human being. And doing that for a potential date—since he’s certainly not guaranteed one just by becoming a nicer guy—doesn’t seem like enough of a reason.

But changing for a friend who is practically family? That sounds about right.

Emmet Asher-Perrin probably spends too much time coming up with background for the Marauders. You can bug her on Twitter and Tumblr, and read more of her work here and elsewhere.