Middle English quene, "pre-eminent female noble; consort of a king," also "female sovereign, woman ruling in her own right," from Old English cwen "queen, female ruler of a state; woman; wife," from Proto-Germanic *kwoeniz (source also of Old Saxon quan "wife," Old Norse kvaen, Gothic quens), ablaut variant of *kwenon (source of quean), from PIE root *gwen- "woman."
The most ancient Germanic sense of the word seems to have been "wife," which had specialized by Old English times to "wife of a king." In Old Norse the cognate word was still mostly "a wife" generally, as in kvan-fang "marriage, taking of a wife," kvanlauss "unmarried, widowed," kvan-riki "the domineering of a wife."
In reference to anything personified as chief or greatest, and considered as possessing female attributes, from late Old English. Figuratively, of a woman who is chief or pre-eminent among others or in some sphere by 1590s. Queen-mother "widow of a king who is also the mother of a reigning sovereign" is by 1570s (colloquial queen mum is by 1960).
English is one of the few Indo-European languages to have a word for "queen" that is not a feminine derivative of a word for "king." The others are Scandinavian: Old Norse drottning, Danish dronning, Swedish drottning "queen," in Old Norse also "mistress," but these also are held to be ultimately from male words, such as Old Norse drottinn "master."
The chess piece (with the freest movement and thus the most power in attack) was so called from c. 1400. As a verb in chess, in reference to a pawn that has reached the opponent's side of the board and become a queen (usually), from 1789. The playing card was so called from 1570s.
Of bees from c. 1600 (until late 17c., they generally were thought to be kings; as in "Henry V," I.ii, but the Anglo-Saxons knew better: their word was beomodor); queen bee "fully developed female bee," the mother of the hive, is used in a figurative sense by 1807.
Meaning "male homosexual" (especially a feminine and ostentatious one) is certainly recorded by 1924; probably as an alteration or misunderstanding of quean, which is earlier in this sense but had become obscure. Cincinnati, Ohio, has been the Queen City (of the West) since 1835. In reference to an extra-large bed size (but generally smaller than king), by 1959.