Titans were the older gods, the first two generation of gods in Greek mythology. The older two generations included Uranus and his son, Cronus, Whereas Olympians were the third generation of gods. They were led by Zeus who was the son of Cronus. These two generations fought to decide who would rule the Universe. Other than that, there were also some other reasons behind the war. The war called the war of Titans or Tauromachic.
There was a series of events that led to the War between the gods. Before the war, Uranus was in power but he was defeated by his son Cronus because he locked some of his children in Tartarus, which was a prison in underworld. Later when he was defeated, Uranus predicted that Cronus too, would be defeated by his son. Cronus was afraid so, whenever his wife, Rhea gave birth to a child, he devoured them. Moreover, he sent his brothers, who were imprisoned by Uranus, back to Tartarus. But his wife managed to save child from him and fooled him into eating a stone in place of the child. The child was named Zeus and he was raised on the Island of Crete by a goat named Amalthea. Once Zeus grew up, he went to his mother and managed to serve his father as a cupbearer. Later, he gave his father a potion, which was given to him by a Titan goddess named Mates, in a drink which resulted in Cronus being sick and he threw up all his children that he had eaten before. And when all the siblings were free, Zeus talked them into rebelling against their father. This rebellion of siblings started the ten years War of Titans.
Tauromachic also known as the war of Titans, is the series of battles that was between two Generations of Greek gods, Titans and Olympians. It actually started when Zeus made alliance with his siblings; Hestia, Demeter, Hera, Hades and Poseidon to fight a war against their father. They escaped to Mount Olympus and hence, called Olympians.
Once they escaped to Mount Olympus, they decided to fight their father and by taking his place, rule the world. They made a plan and declared the war against Titans. They were young and small in number. It seemed that they would soon be defeated but they were desperate to fight against their father, not only for obtaining power to rule the world but also save themselves from their father. Although they were at disadvantage but they never retreated. Later, Prometheus, who could foresee the future, with the help of his ability had a dream that Olympians would win the war and Titans would be defeated. Thus, Prometheus with some other Titans abandoned Titans and joined Olympians in their fight. Other Titans who joined Olympians were Themis and Impetus. Atlas, another Titan was the one who had led the Titans into the war and was the one fighting from the side of Titans. The war continued for almost ten years.