The common guinea pig was first domesticated as early as 5000 BC for food by tribes in the Andean region of South America (present-day Ecuador, Peru and Bolivia).
Statues dating from ca. 500 BC to 500 AD that depict guinea pigs have been unearthed in archaeological digs in Peru and Ecuador.
The Moche people of ancient Peru worshipped animals and often depicted the guinea pig in their art. From ca. 1200 AD to the Spanish conquest in 1532, selective breeding resulted in many varieties of domestic guinea pigs, which form the basis for some of the modern domestic breeds.
They continue to be a food source in the region; most households in the Andean highlands raise the animal, which subsists off the family's vegetable scraps. Folklore traditions involving guinea pigs are numerous; they are exchanged as gifts, used in customary social and religious ceremonies, and frequently referenced in spoken metaphors. They also play a role in traditional healing rituals by folk doctors, or curanderos, who use the animals to diagnose diseases such as jaundice, rheumatism, arthritis and typhus. They are rubbed against the bodies of the sick, and are seen as a supernatural medium. Black guinea pigs are considered especially useful for diagnoses.
The animal also may be cut open and its entrails examined to determine whether the cure was effective. These methods are widely accepted in many parts of the Andes, where Western medicine is either unavailable or distrusted.
Spanish, Dutch and English traders brought guinea pigs to Europe, where they quickly became popular as exotic pets among the upper classes and royalty, including Queen Elizabeth I. The earliest known written account of the guinea pig dates from 1547, in a description of the animal from Santo Domingo; because cavies are not native to Hispaniola, the animal was likely introduced there by Spanish travelers. The guinea pig was first described in the West in 1554 by the Swiss naturalist Konrad Gesner. Its binomial scientific name was first used by Erxleben in 1777; it is an amalgam of Pallas's generic designation (1766) and Linnaeus's specific conferral (1758).