A close-up of Black Hat from 1063: Kill Hitler
|First appearance||12: Poisson|
Black Hat is a stick figure character in xkcd. He is distinguished by his eponymous black hat. In his earliest appearances, Black Hat wore a taller top-hat style hat, that quickly evolved to have the current shape and style of a pork pie hat. Judging by 1139: Rubber and Glue, he has worn the hat since he was a child. Within that strip, a young Hairy also gave him the nickname "Hatboy". Black Hat seems to have short hair, as shown in "Journal" series, 412: Startled and 1401: New. He is revealed to be a blogger in the Secretary series, when Cory Doctorow referred to him as "one of our own". Unlike many other characters in xkcd, he seems to represent the same character in every appearance.
As stated in the title text of 29: Hitler, "the hat guy" is based on a character named Aram from the now-defunct webcomic Men in Hats. Like Black Hat, Aram seems to have frequently made judgmental, insulting or controversial comments in a very emotionless manner. This may also have been the comic where Black Hat truly comes into existence for the first time. He appears earlier in numbering with 12: Poisson, but that was actually first released more than a month later, and put up onto xkcd together with all the old LiveJournal comics when they were re-released on the new xkcd site. Then there is also 24: Godel, Escher, Kurt Halsey, which were released a good month earlier (and drawn during an 'unending Nasa lecture'), so the oldest with a possible Black Hat. But here Black Hat does not really resemble his later appearances.
Black Hat does not appear to have originally been a reference to Black hat hacking. However, the character has evolved to have very similar motivation, hatching evil schemes often for no reason other than to cause chaos or go against the societal norms. He has found a female counterpart and partner in Danish.
Black Hat's hat appears white in 1005: SOPA due to the colours being inverted. (Black Hat is only visible by manipulating brightness and contrast.)
He may also be a reference to the black hat/white hat hacker dichotomy.
It is possible that Black Hat has a name that has been used in the actual webcomic, as opposed to the name "Black Hat." In the title texts of 29: Hitler and 493: Actuarial, Black Hat is referred to as "the hat guy" and "Hat guy" respectively. In 1139: Rubber and Glue, Black Hat is referred to as "Hatboy".