"How Do You Sleep?" is a song by English rock musician John Lennon from his 1971 album Imagine. The song makes angry and scathing remarks aimed at his former Beatles bandmate and songwriting partner, Paul McCartney. Lennon wrote the song in response to what he perceived as personal slights by McCartney on the latter's Ram album. The track includes a slide guitar solo played by George Harrison and was co-produced by Lennon, Phil Spector and Yoko Ono. Composition and lyrics John Lennon wrote "How Do You Sleep?" in the aftermath of Paul McCartney's successful suit in the London High Court to dissolve the Beatles as a legal partnership. This ruling had followed the publication of Lennon's defamatory remarks about the Beatles in a December 1970 interview with Rolling Stone magazine, and McCartney and his wife, Linda, taking full-page advertisements in the music press, in which, as an act of mockery towards Lennon and Yoko Ono, they were shown wearing clown costumes and wrapped up in a bag. Following the release of McCartney's album Ram in May 1971, Lennon felt attacked by McCartney, who later admitted that lines in the song "Too Many People" were intended as digs at Lennon. Lennon thought that other songs on the album, such as "3 Legs", contained similar attacks although McCartney denied it. The lyrics of "How Do You Sleep?" refer to the "Paul is dead" rumour ("Those freaks was right when they said you was dead"). The song begins with the line "So Sgt. Pepper took you by surprise", referring to the Beatles' landmark 1967 album. Preceding this first line are ambient sounds evocative of those heard at the beginning of the Sgt. Pepper's Lonely Hearts Club Band album. The lyrics "The only thing you done was yesterday / And since you've gone you're just another day" are directed at McCartney, referencing the Beatles' 1965 song "Yesterday" and McCartney's hit single "Another Day", released in February 1971. Lennon initially penned the lyrics "You probably pinched that bitch anyway", as a reference to McCartney's claims that he was not sure if he had plagiarized "Yesterday", having asked Lennon, Harrison, George Martin and others if they had heard that melody before. Although Lennon received the sole writing credit for "How Do You Sleep?", a contemporary account by Felix Dennis of Oz magazine indicates that Yoko Ono, as well as Allen Klein, Lennon's manager, also contributed lyrics.