As Time Goes By   Herman Hupfeld, Rudy Vallee (#1 in 1943), Jacques Renard (#3 in 1943),
Jimmy Durante, Movie Themes, Casablanca

You must remember this
A kiss is still a kiss
A sigh is still a sigh
The fundamental things apply
As time goes by
And when two lovers woo
They still say: "I love you"
On that you can rely
No matter what the future brings
As time goes by
Moonlight and love songs - never out of date
Hearts full of passion - jealousy and hate
Woman needs man - and man must have his mate
That no one can deny
It's still the same old story
A fight for love and glory
A case of do or die
The world will always welcome lovers

~ from the 1931 Stage musical Everybody's Welcome by Herman Hupfeld. In 1942, when Casablanca was written, Warner Brothers was looking for a song that sounded like an old familiar saloon song.  They found "As Time Goes By" in their own collection and didn't have to pay for it.

~ Additionally, after it was filmed, it was determined that they wanted to change the song, however it was not possible because Ingrid Bergman cut her hair in preparation for her next film role, so they could not go back and re-film.