The song features vocals by American musicians Justin Timberlake and Timbaland. It was recorded at Sarm West Studios in London, while the mixing of the track was finished at The Hit Factory studio in Miami. Sound engineer Demacio "Demo" Castellon first worked on the vocals of the track, by honing them according to his instincts, and then worked on the beats and the synths composed by Timbaland and Danja. An uptempo dance song with an urban, hip hop style, "4 Minutes" also incorporates Timbaland's characteristic bhangra beats and the instrumentation used in the song includes brass, foghorns and cow bells. The song's lyrics carry a message of social awareness, inspired by Madonna's visit to Africa and the human suffering she witnessed there.
"4 Minutes" has been praised by many contemporary critics who called it a busy, dance track and complimented its music, which was compared to that of a marching band. Some however noted that Madonna, rather than Timberlake, appeared as more of a featured artist in the song. "4 Minutes" achieved worldwide success by reaching number one in twenty-one countries, including Australia, Canada, Germany, Italy, Spain and the United Kingdom. In the United States, "4 Minutes" peaked at number three on the Billboard Hot 100, giving Madonna her 37th top-ten single, breaking the record previously held by Elvis Presley as the artist with most top-ten hits.
In the song's accompanying music video, Madonna and Timberlake sing and run away from a giant black screen that devours everything in its path. At the end of the video, Madonna and Timberlake are consumed by the screen. "4 Minutes" was performed by Madonna on the promotional tour for Hard Candy and the Sticky & Sweet Tour. In the latter, the song served as the opener of the rave segment, where Madonna wore a futuristic robotic dress. During performances of the song, Timberlake and Timbaland appeared on video screens and sang their lines. The song received two Grammy Award nominations for "Best Pop Collaboration with Vocals" and "Best Remixed Recording, Non-Classical."