I feel like the Harry Potter series has a lot of racism hidden in it. We hear terms like "pureblood" and "mudblood" and "blood traitors" used to classify characters and how much of a wizard they are (if that makes sense). Think about the house elves also. They were unfairly treated and used as slaves by wizards. Remember Dobby? He was a house elves to the Malfoys and they treated him terribly. He could even say anything against them in fear of being beaten or punished. This kind of makes me think of slavery way back in history. It was kind of the same deal.
I feel like Voldemort is a really interesting character to look at in the case of racism. His father was a Muggle (a non magical person) and his mother a witch. She tricked his father into falling in love with her and having Tom Riddle (aka Voldemort) and then he left her. Because of this Voldemort had a terrible childhood which caused his hatred of Muggles and those who are pureblood. He sorta reminds me of Hitler. Hitler was a guy who had warped views of the world and wanted to destroy those who were not of the "pure race". And Voldemort wants to have a pure race of people (I mean wizards). This connection is very strong in their believe for wanting a pure race of people. I always felt like Voldemort was just really someone who didn't understand the Muggles or because of his father and rough childhood choose to be an evil person. Do you remember how he pretty much brainwashed people into believe the pure bloods were the superior race (like Hitler with the Nazis) and they all (or most of them) just believed him? I find this to be a very strong connection between these two figures.
I think we see racism the most in Harry Potter and the Deathly Hallows. During this book we see the persecution of mudbloods and halfbloods. Their trials and how they are treated. I think that maybe we should all see that this really does connect to the real world and not just with my Hitler analysis with Voldemort. This has happened again and again and I think that J.K. Rowling has done a good job showing an example of this.