The Mad Hatter first appeared in Batman #49 (October-November 1948) in a story that also introduced Vicki Vale.
But the next time Batman and Robin encountered a "Mad Hatter", he didn't look anything like the one from back in 1948.
From Detective Comics #230 (April 1956):
This was the version of the Mad Hatter that was in new Batman stories through the 1970s.
However, in the early 1980s, someone closer to the original 1940s vewrsion returned.
And from Who's Who: The Definitive Directory of the DC Universe Vol. XIV (April 1986),