"emotional condition, state of mind as regards passion or feeling," c. 1300, from Old English mod "heart, frame of mind, spirit; courage, arrogance, pride; power, violence" (also used to translate Latin animus, mens), from Proto-Germanic *mōda- (source also of Old Saxon mod "mind, courage," Old Frisian mod "intellect, mind, intention," Old Norse moðr "wrath, anger," Middle Dutch moet, Dutch moed, Old High German muot, German Mut "courage," Gothic moþs "courage, anger"), a word of unknown origin (Boutkan finds no acceptable IE etymology).
A much more vigorous word in Anglo-Saxon than currently, and used widely in compounds (such as modcræftig "intelligent," modful "proud"). The Old English senses now are obsolete. Meaning "a fit of bad temper; sullenness, sudden anger" is by 1859. To be in the mood "in a state of mind to be willing (to do or omit something)" is from 1580s. First record of mood swings is by 1939.
"grammatical form indicating the function of a verb," 1570s, an alteration of mode (n.1). The grammatical and musical (1590s) usages of it influenced the meaning of mood (n.1) in such phrases as light-hearted mood, but it is worth remembering that the two moods have no etymological relationship. Also used in traditional logic (1560s) as a variant of mode.