Kirk Hammett co-wrote the music for Metallica's “Enter Sandman” on The Black Album. The song's credited composers are Hammett, James Hetfield, and Lars Ulrich, while Hetfield wrote the lyrics.
Hammett developed the central guitar riff after being influenced by Soundgarden's 1989 album Louder Than Love. The initial idea was shorter, and Ulrich suggested a different pattern of repetition that helped create the song's instantly recognizable opening.
The instrumental structure came together before the final lyrics. Hetfield initially struggled with the words because the music sounded especially catchy and commercial. The finished lyrics turned the song toward darker themes involving childhood fears, bedtime rituals, and nightmares.
The song became one of Hammett's most identifiable contributions to Metallica's catalog. It was the lead single from the 1991 album, reached number 16 on the Billboard Hot 100, and has remained a regular part of the band's live performances.