The origin of the phrase is obscure, with multiple different explanations and no evidence to support any particular one over the others. The first recorded use of the phrase is in the Middle English text Controversial Tracts by John Wyclif in 1380.
In the British TV show The Prisoner, the beginning of each episode contains the phrase, stating that the village authorities will gain information from the protagonist Number Six "by hook or by crook."