Anathema derives from Ancient Greek: ἀνάθεμα, anáthema, meaning "an offering" or "anything dedicated", itself derived from the verb ἀνατίθημι, anatíthēmi, meaning "to offer up". In the Old Testament, it referred to both objects consecrated to divine use and those dedicated to destruction in the Lord's name, such as enemies and their weapons during religious wars. Since weapons of the enemy were considered unholy, the meaning became "anything dedicated to evil" or "a curse".
"Anathema" was initially used in its ecclesiastical sense by St. Paul to mean the excommunication of a heretic or an unrepentant excommunicated heretic. By the 6th century, the liturgical meaning evolved again to mean a formal ecclesiastical curse of excommunication and the condemnation of heretical doctrines, the severest form of separation from the Christian church issued against a heretic or group of heretics by a Pope or other church official.
In 1526, anathema appeared in English for the first time and was used in the sense of "something accursed". The "consecrated object" meaning was also adopted a short time later, but is no longer widely used. Its most common modern usage is in secular contexts where it is used to mean something or someone that is detested or shunned.
The Old Testament applied the word to anything set aside for sacrifice, and thus banned from profane use and dedicated to destruction—as, in the case of religious wars, the enemy and their cities and possessions. The New Testament uses the word to mean a curse and forced expulsion of someone from the Christian community.
The Greek word ἀνάθεμα (anathema), meaning something offered to a divinity, appeared in the translation of the Jewish Bible known as the Septuagint to render the Hebrew word חרם (herem), and appears in verses such as Leviticus 27:28 to refer to things that are offered to God and so banned for common (non-religious) use. The Hebrew word was also used for what was devoted, by virtue of a simple vow, not to the Lord, but to the priest. In postexilic Judaism, the meaning of the word changed to an expression of God's displeasure with all persons, Jew or pagan, who do not subordinate their personal conduct and tendencies to the discipline of the theocracy, and must be purged from the community—thus making anathema an instrument of synagogal discipline.