This is the tenth of the twelve labors of Heracles.
Geryon, the son of Chrysaor and a grandson of Oceanus, inhabited an island on the ocean. He owned red cattle, which were guarded by a shepherd and Geryon's dog, Orthos. Geryon had the lower body of three men, who all joined together at the waist.
Heracles made a treacherous journey west, fighting many beasts. As he came to the end of the lands in Africa, he erected the Pillars of Heracles. As he stood there, he became irritated by the sun, which was making him hot. Taking up his bow, he aimed his arrow at the sun. Admiring his audacity, Helios gave Heracles a golden cup, which he used to sail to Geryon's island.
There, Heracles killed Orthos and the shepherd, and then he drove the cattle back down to his ship. Seeing him drive away the cattle, Geryon attacked. Heracles killed him with an arrow. He then herded the cattle on to his boat/cup.
Heracles had an even more difficult time returning. First, one cow ran off onto the island of Sicily. There, the king Eryx hid this cow among his own. When Heracles approached, Eryx refused to return the cow. He said that Heracles must beat him in a wrestling match. During the match, Heracles killed Eryx.
Later, while driving the cattle over Greece, Hera sent a gadfly. This fly caused the cattle to separate across the countryside. Heracles managed to recapture some, but others were left behind. When he finally handed the cattle over to Eurystheus, the king sacrificed the cattle to Hera.