In the original books he is quoted saying "I am mad because dogs wag their tales when theyre happy and growl when they're angry and I do the opposite" Or something like that )too lazy to google it)
Basically he only THINKS he's crazy because he doesnt know he's a cat. He also probably grew up in Wonderland. I don't think he's evil or crazy at all. Just confused.
Also in the new movie he saves the hatter.