"Have You Ever Seen the Rain" was written by John Fogerty, who wrote both the music and the lyrics. Creedence Clearwater Revival recorded it in November 1970, and it was released as a single on 29 December 1970, with "Hey Tonight" on the B-side. The song appeared on the album Pendulum. Written in the key of C, it is an American rock song with roots rock and country rock elements, and its lyrics are in English. Cash Box described it as "as close to a ballad as anything from CCR". Fogerty said the song concerns the impending breakup of the band and the departure of his brother Tom Fogerty, while its literal subject is a sunshower, a rain common in the Deep South.
The single reached number one on the RPM 100 in Canada in March 1971, number eight on the Billboard Hot 100 and number three on the Cash Box pop chart, and it reached number 36 in the UK. Later versions include Fogerty's live recording on The Long Road Home (2005), a new recording with Alan Jackson on Wrote a Song for Everyone (2013), and versions by Bonnie Tyler, Johnny Cash, Joan Jett, the Ramones and Rod Stewart.