The origins of the gods of ancient Greek religion are described in the Theogony, the famous poem which was composed by the Greek writer Hesiod around 700 BC, and the Library of Apollodorus.
The creation of the gods needs to be divided into four parts:
First there was Chaos, a rough unordered mass of things, also considered as a void. Chaos was followed by Gaea (Earth) and Eros(Desire), who came to cancel every logical thought or act. Gaea then brought Uranus (the Heaven), the infinite Pontus (the Sea) with his raging waves and high mountains full of forests to the world.
Uranus' task was to surround and cover Gaea with his starry coat, however, it very soon came to a union between Uranus and Gaea and they became the first divine couple in the world.
Gaea bore Uranus twelve Titans: the deep Oceanus, Coeus, Crius, Hyperion, Iapetus, Theia, Rhea, Themis, Mnemosyne, the golden-wreathed Phoebe the charming Tethys, and Cronus, who was the youngest of all. Furthermore, she produced three one-eyed creatures called Cyclopes (Brontes, Steropes and heady Arges), as well as three hundred-handed creatures called Hecatonchires.
Uranus was fearful of his children overthrowing him, so he pushed his children back one by one into the womb of Gaea. His wife Gaea was in deep grief and sorrow over the loss of her own children, so in the end she decided to hand a sickle to her son Cronus, the youngest of the Titans, in order to castrate his father.
Cronus castrated his father while he was sleeping; the blood from Uranus was collected by Mother Earth Gaea and she produced Erinyes (Furies), Giants and Nymphs. Cronus then threw his father's genitals into the sea, around which foams developed, that started in the island of Kythera and then slowly made their way to the island of Paphos, in modern Cyprus. In Paphos, the foams transformed into Aphrodite, the Olympian goddess of Love and Beauty.
Soon afterwards, Cronus rescued his brothers and sisters and shared the World (the Cosmos) with them.
Then, Cronus married his sister Rhea and together they created children who would later on become the Olympian gods.
However, Cronus became fearful as well so he started to swallow his own children, just like his father. Rhea was highly discomforted, so, in her attempt to save her youngest child, Zeus, she tricked her husband by giving a huge stone to swallow. Rhea then sent Zeus to the Greek island of Crete in order to protect him.
Zeus grew up in the island of Crete. He was fed by the goat Amaltheia and the Nymphs took good care of him.
Doves brought him ambrosia from far away to eat and an eagle brought him nectar to drink. When he reached manhood, as prophesied, Zeus rescued his five elder brothers and
sisters and then started a war against his father and the Titans.
This war is also known as also known as the "Titanomachy".
In this battle, Zeus succeeded in overthrowing Cronus, casting him and the other Titans into the depths of the Underworld. A huge battle with the Giants followed, where the Olympian Gods excelled... and then time had come for the Olympian gods to rule the world!