mid-15c., apparently from Old French barater "to barter, cheat, deceive, haggle" (also, "to have sexual intercourse"), 12c., of uncertain origin, perhaps from a Celtic language (cf. Irish brath "treachery"). Connection between "trading" and "cheating" exists in several languages. Related: Bartered; bartering. The noun is first recorded 1590s, from the verb. 

Then again, it’s one thing to keep a community alive and well when everyone’s camping in a forest and they’ve all opted in to that vision. It’s quite another to imagine a gift economy enabling humans to build skyscrapers, invent iPhones, put air conditioners in every house, and explore space. (The same goes for collecting taxes and running large businesses.) Not that it’s an all-or-nothing situation: We already have gift economies among friends and family. Perhaps expanding that within small communities is possible; it’s certainly desirable.
Trade did occur in non-monetary societies, but not among fellow villagers. Instead, it was used almost exclusively with strangers, or even enemies, where it was often accompanied by complex rituals involving trade, dance, feasting, mock fighting, or sex—and sometimes all of them intertwined. Take the indigenous Gunwinggu people of Australia, as observed by the anthropologist Ronald Berndt in the 1940s: 

Economic historian Karl Polanyi has argued that where barter is widespread, and cash supplies limited, barter is aided by the use of credit, brokerage, and money as a unit of account (i.e. used to price items). All of these strategies are found in ancient economies including Ptolemaic Egypt. They are also the basis for more recent barter exchange systems.[17]
No academics I talked to were aware of any evidence that barter was actually the precursor to money, despite the story’s prevalence in economics textbooks and the public’s consciousness. Some argue that no one ever believed barter was real to begin with—the idea was a crude model used to simplify the context of modern economic systems, not a real theory about past ones.