Atlas and his brother Menoetius sided with the Titans in their war against the Olympians. When the Titans were defeated, many of them (including Menoetius) were confined to Tartarus, but Zeus condemned Atlas to stand at the western edge of Gaia (the Earth) and hold up Uranus (the Sky) on his shoulders, to prevent the two from resuming their primordial embrace. Thus, he was Atlas Telamon, "enduring Atlas," and became a doublet of Koios, the embodiment of the celestial axis around which the heavens revolve.
A common misconception today is that Atlas was forced to hold the Earth on his shoulders, but Classical art shows Atlas holding the celestial spheres, not a globe; the solidity of the marble globe born by the renowned Farnese Atlas may have aided the conflation, reinforced in the 16th century by the developing usage of atlas to describe a corpus of terrestrial maps.