The piano from Rick’s Café Américain, the bar owned by Humphrey Bogart’s character in the film Casablanca, has been sold at auction in New York for £2.1 million.

In the film, the small upright piano is played by the actor Dooley Wilson, to whom Ilsa Lund, played by Ingrid Bergman, uttered the — much misquoted — line: “Play it, Sam. Play As Time Goes By.”

The instrument’s value as a Hollywood trophy has much to do with its role as a plot device. In Casablanca, which was released in 1942 and is set during the Second World War, the piano is used to hide letters of transit, which will allow the bearer to travel through Nazi-occupied countries.