Way back in medieval times there was the English cokewold, which eventually became our modern cuckold. The first bit is also the source of our cuckoo, with –old attached as a suffix giving a pejorative sense.
Some bright wordsmith of the fifteenth century took the old word and changed the first bit into wete, the quality of awareness or knowledge. (This is our modern word wit in slight disguise, as in witting, the opposite of the more common unwitting). So the idea behind wittol of somebody who knows he is a cuckold, but especially somebody who is happy about the situation.
This was not a state of affairs that most spectators thought reasonable or likely, so the word later took on a sense of a half-witted person, a fool. It was not accidental that William Congreve entitled a character in his play The Old Bachelor Sir Joseph Wittol. Shakespeare borrowed the adjective in The Merry Wives of Windsor: “I know him not; yet I wrong him to call him poor; they say the jealous wittolly knave hath masses of money; for the which his wife seems to me well-favoured”.
The word has pretty much gone out of use, and most old books in which you will find the word use it of a fool, but a few writers retained the cuckold sense as late as the nineteenth century. Here’s an example from an American literary magazine of 1840: “I knew full well that the wittol husband is a subject of ridicule rather than sympathy, and therefore, carefully concealed my suspicions”.