An English word starting with a kak sound suggests something bad or unpleasant, by analogy with words such as cacography for bad handwriting and cacophony for a horrible discordant noise. These join a plethora of medical terms, mostly long obsolete, that include cacothymia, a disordered state of mind, and caconychia, decaying nails.) Cack, dung or faeces, is a distant relative.
Cacoethes is of the same sort. It’s an uncontrollable urge to do something, especially something harmful. The first part is from Greek kakos, bad. To it has been added ethos, a disposition, making a word for a bad habit. It arrived in English unchanged via Latin.
It’s almost, but not quite, as rare as some of those medical terms, appearing sporadically in prose of the more elevated or pretentious sort. (I was astonished to find hundreds of usages in newspapers in the late 1980s. Was this a sudden outburst of classical erudition? Alas not, just a successful racehorse. If it had been named as an attempt at inverted magic, it seems to have worked.)
In a dictionary of quotations of 1808, D E Macdonnel commented that cacoethes was never written alone, but always in combination with some other word. That’s not true today, but one of his phrases is a Latin tag still known and quoted: cacoethes scribendi. It’s from the Satires of the Roman author Juvenal: “Tenet insanabile multos scribendi cacoethes”; in English, “many suffer from the incurable disease of writing”. Aspiring wordsmiths should note that an uncontrollable urge to write doesn’t necessarily lead to anything worth reading.
Macdonnel also listed the vastly less common cacoethes loquendi, a compulsive desire to speak, where the second word derives from Latin loqui, to speak (also the source of loquacious); and cacoethes carpendi, where carpendi is from Latin carpere, to pick, pluck or seize. He defined this as a rage for collecting, but more usually it has been an irresistible desire to criticize or find fault.