Character Analysis
Like the other characters in the book, Twain doesn't waste much time on Merlin's physical description. He looks pretty much like we all expect: "a very old and white-bearded man, clothed in a flowing black gown" (3.4). But anyone expecting Arthur's famous court magician to act like one of the good guys is in for a rude surprise. The Merlin in this book is a sneaky, two-faced snake oil salesman, out to get Hank from the beginning, which makes him the chief baddie in Arthur's kingdom, and the one guy who keeps giving Hank a hard time.
Luckily for Hank, Merlin can't even practice real magic: Hank shows him up time and again, treating him like a punching bag in a pointy hat for most of the book. Most of it is Merlin's own fault: he trusts nonsense superstitions and fancy magic spells that don't do anything, instead of his brains like he should:
If he had stepped in there and used his eyes, instead of his disordered mind, he could have cured the well by natural means, and then turned it into a miracle in the customary way; but no, he was an old numskull, a magician who believed in his own magic. (22.6)
This makes him a symbol of all of Arthur's Britain: the superstitious rubes who believe in silly things just because someone else says they should. It's not Merlin's fault really—okay, he is quite the weasel and he does pull all kinds of dirty tricks on Hank—but as the resident magician in Arthurian literature, he represents all the illogic, fear and superstition that the Yankee is fighting against.
In this way, Merlin is the ideal antagonist for Hank. He constantly bad-mouths Hank behind his back, and only at the very end does he show any real magic—and then only enough to send Hank to sleep before completely going off his rocker and dying on a length of electric wire.
Besides that grim little final note, however, Twain makes Merlin a satirical figure. He can't do anything right (besides sporting the occasional sneer and evincing the kind of sleazy cunning found in your average small-town politician), and Hank takes a lot of pride in cutting him down to size:
I sent Merlin home on a shutter. He had caved in and gone down like a landslide when I pronounced that fearful name, and had never come to since. He never had heard that name before—neither had I—but to him it was the right one. Any jumble would have been the right one. (23.10)
Merlin isn't just a subpar wizard, though—he also represents the larger world that Hank is trying to change, and that gives him a kind of unseen power that the Yankee can't fight. When it all comes apart for Hank, Merlin is the one to deliver the final blow, and even though the old wizard dies in short order, he ultimately has the last laugh over the do-gooder who just tried to make everything better.