PRAYAGRAJ, India — Every six years, tens of millions of Hindus pour into the northern Indian city of Prayagraj to take a holy dip in the Ganges River. The festival is called the Kumbh Mela, and in its different forms it is consistently the biggest gathering of humanity on the planet.
This year, it also coincides with national elections, an opportunity that Prime Minister Narendra Modi and his allies have eagerly seized.
They have turned this Kumbh, which is technically only a half Kumbh (more on that later), into the biggest, most lavish and most expensive in Indian history, using it to please their political base and deflect from their growing woes.
It is nearly impossible to take 20 steps along the pilgrimage route without passing a huge sign featuring Mr. Modi’s face or the grinning visage of his close ally, Yogi Adityanath, the monk turned chief minister of this state, Uttar Pradesh. They aren’t technically campaign ads but billboard after billboard trumpets their accomplishments in all areas of life.
Here’s Mr. Modi on a super-bright video screen talking about his Clean India campaign, the bluish glow lighting up countless pilgrims sleeping on the ground. There’s Mr. Adityanath grinning from the side of a water truck, welcoming visitors — an estimated 35 million of them on Monday alone.
In India, politics and religion are often inseparable, especially with Mr. Modi’s Hindu nationalist bloc, the Bharatiya Janata Party, in control. He and Mr. Adityanath, who is considered even further to the right, have expanded this Kumbh into a $600 million affair that brought nine new highway flyovers, 22 pontoon bridges, 150 miles of roads, 20,000 trash cans, 40,000 LED lights, 122,500 toilets and one new airport terminal.
The timing is a gift. National elections are expected in April or May, and in recent months, Mr. Modi and the Bharatiya Janata Party, or B.J.P., have come under withering fire for troubling weaknesses in India’s economy and for allegations that Mr. Modi tried to suppress data that showed India’s unemployment rate soaring to a 45-year high.
But at the Kumbh, most everybody is Hindu and most seem perfectly happy benefiting from the state sponsorship of their religion, even as other communities are suffering out of sight.
For example, months ago, to ensure the Ganges was as clean as possible for the busloads, trainloads and masses of Hindus coming for their spiritual immersion, Mr. Adityanath went after the tanneries that line the Ganges upstream from Prayagraj.
The tannery business is dominated by India’s Muslim minority and lower-caste Hindus who do not subscribe to the same strict rules about cows that some conservative Hindus follow. But conservative Hindus are the B.J.P.’s base, and Mr. Adityanath ordered the tanneries closed for three months, the longest anyone can remember.
Some tannery owners even went to court, but they were effectively shut down. Now, as tens of millions of Hindus celebrate the Kumbh, countless Muslims and lower-caste tannery employees are out of work.
“This is done purposely just to hurt one segment of society, the Muslim community,’’ said Taj Alam, vice president of the Uttar Pradesh Leather Industry Association.
Mr. Adityanath is a powerful figure in India, perhaps second only to Mr. Modi. His job is a big one: Uttar Pradesh, India’s most populous state, contains 230 million people; it would be the fifth largest country in the world.
Once the commander of a brawny Hindu youth brigade, Mr. Adityanath is also one of India’s most divisive politicians. He is on record making derogatory statements about Muslims and saying he was ready for religious war.
He is also fiercely disciplined, and so is this year’s Kumbh. According to Kumbh regulars, this year’s festival is much cleaner and better organized than previous festivals and many pilgrims gave Mr. Adityanath credit. The traffic flows more smoothly. There are no beggars in sight (police officers said they had been banned). There isn’t even much litter — street cleaners seem to sweep up the empty water bottles and snack wrappers the instant they are dropped.
There are even riverside changing rooms — a first — so pilgrims, especially women, can have a little privacy.
“This is the best Kumbh yet,” said Brijlal Mishra, who sells solar panels in Mumbai, about 750 miles away. Mr. Mishra did not have an issue with the government’s spending spree.
“They are helping us in our faith,” he said.
Opposition leaders, however, have cried foul, saying the state should not help one religion at the exclusion of others.
“We are a secular state, and we should remain secular,” said Sudhindra Bhadoria, a spokesman for the Bahujan Samaj Party, one of India’s bigger second-tier political parties. “Why are they spending taxpayers’ money like this?”
Officially, Mr. Adityanath’s administrators have rejected accusations of misusing state resources or playing politics with the Kumbh. But privately, several called the display of largess a waste.
Case in point is an enormous, festively painted plywood Kumbh Mela assembly hall that is closed most of the time. A peek through the door revealed a fantastically large space, home to 10,000 brand-new empty plastic chairs.
The Kumbh Mela is one of the holiest events on the Hindu calendar, its date determined by astrology, its auspiciousness derived from a certain line up of Jupiter, the moon and the sun. It is celebrated in four different Indian cities, each on their own 12-year Kumbh cycle, and it usually lasts several weeks.
The name Kumbh Mela comes from the Sanskrit word, kumbha, for pot or water pitcher, and mela, meaning festival. In a cherished myth, a Hindu god was carrying the nectar of immortality in a khumba and spilled drops in four different places — the four cities where the Kumbh is held.
But this year’s festival in Prayagraj, which started in January and runs until early March, is not even a full Kumbh — it is considered a half Kumbh. The half Kumbh tradition started years ago when Hindu holy men would meet every six years, halfway between the full Kumbhs, to keep their dialogue going.
But a few months ago, Mr. Adityanath declared that there is nothing incomplete in Hinduism, and the word half “doesn’t gel with this philosophy.” So, with a stroke of his pen, he upgraded the celebration of this half Kumbh into that of a full Kumbh and went on to spend three times as much as on Prayagraj’s last full Kumbh in 2013.
He also recently led his cabinet of about 25 ministers in a ritual bath in the Ganges, which, longtime Kumbh watchers said, had never happened before.
At the Kumbh, it’s all about the dip. In Prayagraj, during this festival, Hindus believe it is auspicious to immerse themselves at a specific point where the Ganges joins two other rivers, the Sarasvati (a mystical one) and the Yamuna (a real one). . But actually getting into the water is easier said than done.
It is nearly impossible to strip down in a packed crowd with just a few inches between you and the next person, no place to put your stuff and an undulating wall of a million human beings at your back.
But somehow people managed, and on Monday morning shortly after dawn, legions of men splashed into the Ganges in their underwear; women wrapped themselves in shawls or just stepped into the water fully clothed. They dunked themselves and chanted.
Many pilgrims believe the water will wash away their sins.
Just a few yards from the riverbanks, Mr. Modi appeared, again. This time, he took the form of a high quality cardboard cutout, so sharp and lifelike you could count the curly gray hairs on his forearms. For a second, it almost looked like the prime minister was personally watching over his fellow Indians as they plunged into the river.
The noise at the riverfront (and all along the pilgrimage route) was deafening. Police officers blasted earsplitting whistles at anyone who lingered too long in the water; “Sri Ram, Sri Ram,” a Hindu chant, blared from loud speakers; train horns blew in the distance, constantly.
Over a public address system, the authorities broadcast the cries of despondent children who had been separated from their parents in the hope that someone in that gigantic multitude would recognize their voice. (“Papa! Papa!” one pleaded.)
The smell of burning popcorn and woody incense cut through the other smells of damp clothes, sweat and dust.
The Ganges was cold and dark, the crowds oceanic, the din ceaseless. But no one was complaining. No matter that people had traveled for days, walked for miles, slept on the ground, and ate little, all for a few minutes in the river. They emerged with goose bumps on their arms and joy on their faces.
“It feels wonderful,” said Ashok Bhatt, a pilgrim who once lived in Tallahassee, Fla.
Daswanti Patel, an impoverished farmer, came from a village a couple hours away in a wagon pulled by a tractor. She was stunned by all the Kumbh bling — the piercing LED lights, the mesmerizing video billboards, the free clean water and the plywood palace rising just behind where she lay in a pile of hay with her husband and granddaughter, under a lumpy old quilt.
“We are not seeing any of this money spent in our area,” she said. “Back home, we live in a house made out of mud and hay.”
Last election, she voted for Mr. Modi. But when asked what she would do this coming election, she frowned and said: “Let’s wait and see.”