The British phrase to throw a spanner in(to) the works means to cause disruption, to interfere with the smooth running of something—synonym (American English): to throw a monkey wrench into.
The earliest instance that I have found is from Mr. Connolly, Music Lover, by the English author Pelham Grenville Wodehouse (1881-1975), published in both The Cincinnati Enquirer (Cincinnati, Ohio) and The Los Angeles Times (Los Angeles, California) on Sunday 15th March 1925:
“Archie, darling, when you married me, you undertook to share my sorrows, didn’t you?”
“Then share ’em!” said Lucille. “Bill’s in love again.”
“Of what caliber is the latest exhibit?”
“Middle West overlaid with Washington Square.”
“Once again!” requested Archie, puzzled.
“Well, I mean she comes from the Middle West and seems to be trying to be twice as Bohemian as the rest of the girls down in Greenwich Village. She wears her hair bobbed and goes about in a kimono.”
“I can’t understand why it is that Bill goes out of his way to pick these horrors. And the worst of it is that one always feels one’s got to do one’s best to get him through.”
“Absolutely! One doesn’t want to throw a spanner into the works of love’s young dream. It behooves us to rally ’round.”
The second-earliest instance that I have found is from The Evening News and Southern Daily Mail (Portsmouth, Hampshire) of Friday 12th August 1927:
The Big Two of the National Union of Railwaymen, the staffs of the different lines have given in their adhesion to the thesis that it is their duty, under the present system, to make the railways as successful as possible. This concession is made “without prejudice,” as the lawyers say. The leaders and workers in the industry wish it to be understood that it is their “unalterable belief” that nationalization should be their ultimate goal. So be it. Nationalization of the railways is not a matter of practical politics at the moment, but there is no necessary harm done by the cherishing of even impossible ideals. It is practical politics, however, to refrain, as one commentator puts it, from throwing a spanner into the works of a machine by which you get your living, especially if you hope and intend eventually to get possession of that machine.
At Blackpool the Arsenal worked like one of those clean, efficient machines which convey the impression of hidden power and a well-directed flow of energy, with James and Jack the dynamic, fool-proof force behind it. Blackpool tried, as it were, to pitch a spanner into the works, but only succeeded in striking the casing.
On Friday 9th October 1931, The Essex Chronicle (Chelmsford, Essex) published a review of Step to a Drum, by the English author Constance Elizabeth ‘Betty’ Inskip (1905-45), in which the following sentence from the novel is quoted:
It’s nearly always love that throws the spanner in the works and makes things first go wrong.
front cover of A Spaniard in the Works, by John Lennon