"Sweet Revenge" is the fourth and final studio album by English punk band Generation X, although it was chronologically their third recorded. The album's material originated from 1979 demo sessions, which were never completed due to the band's breakup later that year. These sessions took place in Olympic Studios and were largely produced by frontman Billy Idol and bassist Tony James. The band had initially rented a house in Oxfordshire to write new songs with a more stripped-down sound, following the commercial failure of their second album, Valley of the Dolls. However, Idol was unhappy with both the rural setting and the material being developed. A notable moment from the sessions was the creation of "Dancing with Myself," which marked a shift toward a new dance-punk style that would influence Idol’s later solo career.
The original recordings were not released until 1998, nearly two decades later, under disputed circumstances. Former guitarist Derwood Andrews, who had left the band on bad terms, provided the tapes to European labels without Idol or James’s consent. He titled the album K.M.D. – Sweet Revenge, referencing the later Kiss Me Deadly album created by Idol and James with their rebranded band, Gen X. Idol opposed the 1998 release, deeming the material unfit for commercial use. A U.S. release was legally blocked at the time, but a version of the recordings was later included in the officially sanctioned Generation X Anthology in 2002. A further unauthorized expanded edition, K.M.D. – Sweet Revenge Xtra, was released in Japan in 2004, again without Idol and James’s approval, and featured alternate mixes and live tracks.