My wife asked me, out of the blue, why we refer to old jokes and stories as “chestnuts.” The short answer is, nobody knows. The OED says: “Origin unknown: said to have arisen in U.S. The newspapers of 1886-7 contain numerous circumstantial explanations palpably invented for the purpose. A plausible account is given in the place cited in quot. 1888”; that account is the one you can find in many places, for instance here:
In a play called ‘The Broken Sword’, by William Dimond, produced at Covent Garden in 1816, a character called Captain Xavier is always repeating unlikely stories about his exploits. On one occasion, talking to a character called Pablo, he mentions a cork-tree. Pablo corrects Xavier, saying that the tree was a chestnut, and ‘I ought to know, for haven’t I heard you tell this story twenty-seven times?’
The play was soon forgotten, but many years later in America, an actor named William Warren Jr recalled this episode at an actors’ dinner, where another speaker had told a stale old joke. The actors who were present picked the phrase up, and ‘an old chestnut’ became a synonym for ‘an old joke’.
That’s probably as good as we’re going to do. Eric Partridge in Origins: An Etymological Dictionary of Modern English says it “prob comes from roasted chestnuts eaten at the gossipy fireside,” which is the kind of vague guess I expect of that genial old soul. The Dictionary of American Regional English doesn’t venture an explanation but does show it as being chiefly in the Northeast and North Midlands. For me it’s part of core vocabulary; I wonder if younger people use it?