A very complicated, "grey" character, in my opinion.
Here's what I've said about him before:
He was not a very nice person, and was a bully to his students. However, he did risk his life to take down Voldemort while pretending to work for him, and while he resented Harry and didn't hide this, he still looked out for him in his own way. It's questionable what his motive was: ultimately, avenging Lily seems to be among the biggest factors, and if she hadn't died, it's possible he may have stayed a Death Eater, but he still did join the "good side" and died a hero. He had a troubled background, and while he made bad choices, I feel he redeemed himself, in the end