The immemorial custom of goddess worship has been prevailing in India since ancient times. There are a number of beliefs and legends of Navratri festival which have been around for ages.
Legend says that when Mahishasura, the spiteful demon, who was a devotee of Lord Shiva, acquired unbeatable powers of eternity, he started taking away innocent lives. In order to stop him from taking over all the three lokas, Lord Brahma, Lord Vishnu and Lord Mahesh of the Hindu Trinity united their supreme powers and created a warrior goddess Durga who entered a war with Mahishasura. This war extended for nine days and on the tenth day she beheaded him. These nine nights signify the festival of Navratri.
As per Hindu mythology, Uma, daughter of King Daksha of Himalayas, married Lord Shiva against the will of her father. In order to take revenge, King Daksha arranged a yagna where he invited all the deities except Lord Shiva. The story goes that when Uma visited her parents to take part in the yagna, her father offended Lord Shiva. Unable to bear the insults meted on her husband, Uma jumped into the agnikund, which is why she is also known as Sati. In her rebirth, she married Lord Shiva and also made peace with her parents. It is said that Sati comes to stay with them for nine days, which is celebrated as Navratri.
It is also said that Lord Rama worshipped Goddess Durga in all her nine forms, for nine days, in order to gather all the powers required to vanquish Ravana the demon, and release his wife Sita from his clutches. Those nine days imply Navratri, and the tenth day when he killed Ravana, came to be known as Vijaydashmi and is celebrated as Dussehra.
The history of Navratri also takes us to the assumption which states that in prehistoric times, the Kshatriyas used to drive themselves out from participating in any warlike activities all through monsoon season. As soon as monsoons got over they would worship Devi for nine days and set off with their war activities. These nine days are today celebrated as Navratri.