At the Merry Angels Public School just outside the capital, New Delhi, the vast majority of more than a dozen voters interviewed on Thursday morning said they had voted for Mr. Modi’s party.

“I’m not even that happy with Modi,” said Vikas Kumar Sau, a rickshaw driver who complained about slum housing and police harassment. “But everyone else was voting for him, so I thought I might as well too.”

The voters moved through long lines to have their identification cards checked and then stepped into cardboard voting booths, where they pushed a button on a long tablet that showed the candidates’ names, photographs and party symbols, which varied from a flower and soccer ball to a pair of scissors. All this unfolded quietly. The loudest sound was the electronic ding after each vote was cast.

A large number of Indians believe that the Modi administration has been more effective, less corrupt and better at positioning India on the world stage than past governments.

But his party has also alienated minorities and created fear. Intellectuals blame the Hindu nationalist atmosphere stoked by Mr. Modi and the party for a rash of lynchings and other violence against Muslims and lower-caste Indians.

The latest surveys predict that Mr. Modi, 68, will return to power. But voter discontent over India’s economic challenges, especially rising joblessness, is likely to reduce the number of parliamentary seats his party controls. That could hamper his ability to push the Hindu nationalist agenda further.