It’s been almost 20 years since Harry Potter was introduced to the world, and the boy wizard is still fighting the forces of evil in the imaginations of millions. But according to a new study, Harry’s victory over the evil Voldemort may not be limited to the pages of a book.

Related Content Neuroscience Explores Why Humans Feel Empathy for Robots

A group of Italian psychologists believe that children who identify with Harry Potter might develop greater empathy and tolerance toward people from disadvantaged backgrounds, including refugees, immigrants and gay people, reports NPR’s Shankar Vedantam. And it might be thanks to Harry’s unhappy childhood.

“Peppered throughout the stories are references to the fact that Harry wasn't brought up in the aristocracy of wizard life,” Vedantam says. “At the same time, there are many characters in the story, many wizards who came from much more privileged backgrounds, who turn out to be the villains of the story.”

While Harry eventually escapes his life among normal people (called “muggles” by his fellow wizards), he quickly discovers that the wonders of the magical world still hides prejudice and bigotry behind wands and robes. By experiencing the world through Harry’s eyes, the psychologists think that perhaps readers may become more attuned to people who often struggle in the real world.

The researchers tested three groups of young people from elementary school-age through university students and found that the Potterheads were more accepting of stigmatized people. But while the researchers used Harry Potter as a benchmark, Vedantam says it might say more about how a good story changes the way you think:

“I think it points to one of the more interesting ideas in fighting determination...which is that the most effective way to do it is not through rational thinking and conscious effort but through narrative and storytelling. When stories allow us to empathize with people who lead very different lives or come from very different backgrounds, it allows us to get into their shoes in a way that no amount of preaching can accomplish.”

While it looks like Harry Potter could fight prejudice in the real world, the study doesn’t say whether listening to Draco and the Malfoys has the opposite effect.