In the 1500s and 1600s AD, many Europeans and West Asians tried to force other people to believe in their religion and their God. In the Americas, the Spanish forced millions of Aztec, Maya, and Quechua people to become Christians. In Europe, wars erupted between Catholics and Protestants. In West Asia, the Shiite Safavids fought the Sunni Ottomans. But in China, Buddhists, Confucianists, and Taoists mixed their beliefs and got along. India was on a middle path: there were Muslims, Hindus, Buddhists, Sikhs, Parsees, and Christians living there; they didn't mix much, but they didn't get into Western-style religious wars or massacres.
The Mughal emperors were Muslims, but as they conquered northern India they began by proclaiming freedom of religion, and for the most part they let Hindus and Parsees and Buddhists worship whatever gods they wanted. By this time, there were not very many Buddhists in India, except in the Himalaya Mountains in the north. Further south in the Deccan and the Chola kingdoms, most people continued to practise Hinduism.
At the same time, European sailing ships were beginning to bring Christian missionaries to India. Christian soldiers killed Muslims on their way to Mecca for the hajj, and in return the Mughal queen Nur Jahan confiscated the Jesuit churches in 1613. But the Christians kept trying to convince more Indians to become Christians.
The Mughal emperor Jahangir, in 1605 AD, continued his father's freedom of religion, except that he led a persecution of Sikh people. Sikhism was pretty new still in 1600 AD, and so people were more suspicious of it. Jahangir's son Shah Jahan also persecuted the Sikhs, and tried to keep out the Jesuits. But beginning in 1658, Shah Jahan's son Aurangzeb really began to persecute anyone who wasn't a Muslim, just the way people did further west. He destroyed famous Hindu temples, and forced people to convert to Islam. Aurangzeb insisted that Sikhs and Hindus and Christians should all become Muslims.
But all this persecution only made the Hindus and Sikhs more determined to keep their own religion and hate the Muslims. After Aurangzeb died in 1707, both the Hindus and the Sikhs formed their own movements, and their own more or less independent kingdoms in India. Just as the Wars of Religion were finally ending in Europe, people in India began to feel that there were big differences between Muslims and Hindus and Sikhs and Christians, and that they could not ever possibly get along.