Gandhi announced his resignation on Twitter, saying he was stepping down because accountability is "critical for the future growth of our party." He said rebuilding the party requires hard decisions and "numerous people will have to be made accountable for the failure."
"It would be unjust to hold others accountable but ignore my own responsibility as president of the party," Gandhi said in his resignation letter. It was unclear whether the left-of-center secular party would accept his resignation.
Gandhi's family, starting with his great-grandfather, Jawaharlal Nehru, has produced three prime ministers. Two of them — his grandmother Indira Gandhi and father, Rajiv Gandhi — were assassinated in office.
Rahul Gandhi lost his own seat, long a Congress party bastion, in the recent elections, marking the end of an era for modern India's most powerful political dynasty. However, he won a seat from another constituency.
He had been talking of quitting since the results of the elections were announced in May, but party officials urged him to stay. Dozens of party supporters joined a strike to pressure Gandhi not to resign.
In the elections, Prime Minister Narendra Modi's ruling Hindu nationalist Bharatiya Janata Party won 303 out of 542 seats in the lower house of Parliament, well beyond the simple majority needed to form a government. The Congress party won 52 seats and the All India Trinamool Congress led by West Bengal Chief Minister Mamata Banerjee won 22.
Gandhi said in his resignation letter that the BJP used state organizations to help it win the elections. "We didn't fight a political party in the 2019 election. Rather, we fought the entire machinery of the Indian state, every institution of which was marshalled against the opposition," Gandhi said. "It is now crystal clear that our once cherished institutional neutrality no longer exists in India."
He said the BJP is "systematically crushing the voice of the Indian people" and that it is his party's duty "to defend these voices." "Our democracy has been fundamentally weakened. There is a real danger that from now on, elections will go from being a determinant of India's future to a mere ritual," he said. "This capture of power will result in unimaginable levels of violence and pain for India."
Arti Jerath, a political commentator, said nothing would change if the Gandhi family remains "the power center of the Congress party." She said Congress needs an election within the party "so that new leaders can come up."
"That is the only way to get fresh blood and ideas. The Gandhi family has to let go. It can't continue the system of patronage," Jerath said. Nilanjan Mukhopadyay, a biographer of Modi, said the way Congress leadership navigates the current crisis will largely determine the future of the party.
"If after all this melodrama, Rahul Gandhi continues either in person or through a proxy president to dominate, it is going to be more damaging for the Congress party than it is now," he said. After inheriting his power, Rahul Gandhi long distanced himself from political life, even after becoming a lawmaker. In Parliament he was largely a backbencher, leaving the party's reins to his mother, Sonia Gandhi. In December 2017 he took over the party's leadership from her after she suffered health problems.
The BJP's victory was largely seen as a referendum on Modi's Hindu nationalist politics that many say have bred intolerance toward Muslims and other religious minorities. Critics say the ruling party's Hindu nationalism has aggravated religious tensions. However, Modi supporters say the tea seller's son from Gujarat state has improved the nation's standing.
Since Modi led the BJP to power in 2014, Hindu mobs have lynched dozens of Muslims and lower-caste dalits for allegedly consuming or slaughtering cows, which Hindus consider sacred.
Associated Press writer Ashok Sharma in New Delhi contributed to this report.