It has been claimed that "gay" was derived as an acronym for "Good As You", but this is a backronym (based on a fake etymology).
Some people believe that "gay" is an an acronym for "good as you." This is a nice theory, but without foundation. "Gay" has had many different meanings in the past. It was used as a synonym for happy by Chaucer in the 14th century. By 1637, it took on the meaning of a person leading a loose and immoral life. By 1825, it was sometimes used to refer to female hookers. By the late 19th century, it meant to be in good health or to be convalescent. A "gay house" was a brothel.
"Gay" was first used to refer to a male homosexual in the 1933 play "Young & Evil." Cary Grant used it in the 1938 movie "Bringing up Baby" to refer to a transvestite. Gershn Legman & G.V. Henry mentioned the term in their book Sexual Variations (1941). In recent years, it has been used to refer to lesbians as well as homosexual males.