The phrase 'a wolf in sheep's clothing' is an allusion to a Biblical passage in the Gospel of Matthew.
"Beware of false prophets, which come to you in sheep's clothing, but inwardly they are ravening wolves."
-- Matthew 7:15
This has been reused and modified many times throughout the centuries. It appeared in Rome as a common proverb, Pelle sub agnina latitat mens saepe lupina (Under a sheep's skin often hides a wolf's mind), and appeared as a cautionary tale that became so common that it was often believed to be one of Aesop's fables; while there is no evidence that Aesop ever wrote a fable in this vein, The Wolf in Sheep's Clothing is still listed as number 451 in the Perry Index of Aesop's works.
The phrase has been elaborated into a number of stories, perhaps first by the Greek writer Nikephoros Basilakis in his collection Progymnasmata. In this story, a wolf put on a sheepskin so that he could sneak into the shepherd's flock, and sure enough, when night came the shepherd locked the wolf in the paddock with the sheep -- but the disguise worked too well, and when the shepherd came to kill a sheep for his dinner, he killed the wolf by accident.
A later story by the 15th century writer Laurentius Abstemius may be more familiar to modern readers. In his Hecatomythium a wolf dressed in a sheep's skin entered into a flock of sheep and killed one sheep each day. Eventually the shepherd noticed what was happening, and hanged the wolf in a tree. when the other shepherds asked him why he had hanged a sheep, the shepherd answered: "The skin is that of a sheep, but the activities were those of a wolf." This story mirrors the message of the Biblical passage, that people should be judged not by their appearance but by their actions.