mid-14c., "pertaining to character or temperament" (good or bad), from Old French moral (14c.) and directly from Latin moralis "proper behavior of a person in society," literally "pertaining to manners," coined by Cicero ("De Fato," II.i) to translate Greek ethikos (see ethics) from Latin mos (genitive moris) "one's disposition," in plural, "mores, customs, manners, morals," a word of uncertain origin. Perhaps sharing a PIE root with English mood (n.1).
Meaning "morally good, conforming to moral rules," is first recorded late 14c. of stories, 1630s of persons. Original value-neutral sense preserved in moral support, moral victory (where the notion is "pertaining to character as opposed to physical action"). Related: Morally.