Merlin is the great magician of Arthurian legend, and his literary origins are as layered as Arthur's own. He emerges from the Welsh figure of Myrddin, a wild prophet-poet, and from Geoffrey of Monmouth's twelfth-century histories, where he is a fatherless boy of prophetic power, before the French romances made him the wizard-counsellor of the whole Arthurian world.
In the developed legend he is born of a mortal woman and an otherworldly (in some tellings, demonic) father, from which he derives his uncanny powers, turned to good ends. He engineers Arthur's very conception, arranges the test of the sword in the stone that reveals the rightful king, establishes the Round Table, and serves as the shaping hand behind the young king's reign, prophet, shape-shifter, and maker of kings. His end is a fall through his own art: enchanted by the enchantress (Nimue or Viviane) to whom he has taught his magic, he is imprisoned forever in a cave, a tree, or a tower of air. Merlin embodies a recurring theme, the power of knowledge and prophecy, and its insufficiency to save even the knower from fate.