India's top court banned politicians from using religion and caste to win votes, weeks ahead of crucial state polls where such affiliations dominate campaigns.
The Supreme Court panel ordered that voting must remain a secular activity and that candidates using religion or caste on the campaign trail would be barred from contesting polls.
The country is officially secular but politicians, including from Prime Minister Narendra Modi's Hindu nationalist Bharatiya Janata Party (BJP), have been accused of exploiting religion and caste to garner votes.
"An appeal in the name of religion, race, caste, community or language is impermissible under Representation of the People Act and would constitute a corrupt practice," a seven-judge bench said.
"Religion has no role in electoral process which is a secular activity. Mixing state with religion is not constitutionally permissible," it ruled.
The court order came after a plea filed in 1990 and fresh petitions on electoral malpractices from activists who wanted a ruling to sever religion from politics.
Five states are due to hold elections including Uttar Pradesh, where religion and caste dominate political discourse.