The term eunuch (/ˈjuːnək/; Greek: εὐνοῦχος) generally refers to a man who has been castrated, typically early enough in his life for this change to have major hormonal consequences. In some ancient texts, "eunuch" may also refer to a man who is not castrated but who is impotent, celibate, or otherwise not inclined to marry and procreate. In Latin, the words , (Greek: σπάδων spadon), and were used to denote eunuchs.
Castration was typically carried out on the soon-to-be eunuch without his consent in order that he might perform a specific social function; this was common in many societies. The earliest records for intentional castration to produce eunuchs are from the Sumerian city of Lagash in the 21st century BC. Over the millennia since, they have performed a wide variety of functions in many different cultures: courtiers or equivalent domestics, treble singers, religious specialists, soldiers, royal guards, government officials, and guardians of women or harem servants.
Eunuchs would usually be servants or slaves who had been castrated in order to make them reliable servants of a royal court where physical access to the ruler could wield great influence. Seemingly lowly domestic functions—such as making the ruler's bed, bathing him, cutting his hair, carrying him in his litter, or even relaying messages—could in theory give a eunuch "the ruler's ear" and impart de facto power on the formally humble but trusted servant. Similar instances are reflected in the humble origins and etymology of many high offices (e.g., chancellor originally denoted a servant guarding the entrance to an official's study).