Overview
Flogging a dead horse (or beating a dead horse in American English) is an idiom meaning that a particular effort is futile, being a waste of time without a positive outcome, e.g. such as flogging a dead horse, which will not compel it to do useful work.
Early usage
The expression is said to have been popularized by the English politician and orator John Bright. Speaking in the House of Commons in March 1859 on Bright's efforts to promote parliamentary reform, Lord Elcho remarked that Bright had not been "satisfied with the results of his winter campaign" and that "a saying was attributed to him [Bright] that he [had] found he was 'flogging a dead horse'."
The earliest instance cited in the Oxford English Dictionary dates from 1872, when The Globe newspaper, reporting the Prime Minister, William Gladstone's, futile efforts to defend the Ecclesiastical Courts and Registries Bill in the Commons, observed that he "might be said to have rehearsed that particularly lively operation known as flogging a dead horse".
Earlier related terms
The phrase may have originated in 17th-century slang, when a horse symbolized hard work. A "dead horse" came to mean something that had become useless. In gambling, "playing a dead horse" meant wagering on something, such as a hand of cards, that was almost sure to lose. In a 17th-century quote from a collection of documents owned by the late Earl of Oxford, Edward Harley,
From Wikipedia (CC BY-SA 4.0).