The construction of the temple cost approximately $240 million.
Vijay Kumar, 18, took four days to reach the city after covering 600 kilometers on foot and hitchhiking. We wanted to be here, he said. We just want to see the temple before we leave.
The 140 kilometers that separate the temple from the city of Lucknow, the capital of the state of Uttar Pradesh, are lined with panels representing the blue-skinned god Rama with a bow and arrows, as well as portraits of Narendra Modi and the region's chief minister, Hindu monk Yogi Adityanat.
Some say that the event is being used to take an electoral turn. So be it. At least they are doing what they promised and we must have the power to do things for the people, says Prem Sharan, a 35-year-old resident of Ayodhya.
Other pilgrims have arrived via the newly built international airport and will stay in new hotels planned to accommodate the millions of pilgrims expected each year.
Several celebrities were expected to attend the ceremony, including former national cricket team captain Virat Kohli and Bollywood film star Amitabh Bachchan.
Narendra Modi and the BJP have sought to promote Hinduism and bring it to the forefront since coming to power years ago is ten years old.
Hindus believe that Rama, one of the most revered gods in the pantheon, was born in the city of Ayodhya over 7,000 years ago and that the Babri Mosque was built at his birthplace by a 16th-century Muslim emperor.
BJP leaders regularly describe periods of Islamic rule over parts of India as slavery that oppressed Hindus, using the example of Ayodhya to support this narrative.
The BJP played a key role in the campaign that led to the destruction of the mosque, even though it was not in power, by organizing processions across the country that sparked multiple religious riots in their wake.
The inauguration of the temple by Narendra Modi alongside Hindu priests should strengthen his position as defender of the faith, before the legislative elections in April.
The BJP is heavily favored to score a third straight victory, thanks in part to the prime minister's pro-Hindu policies.
Parties opposition boycotted the ceremony, claiming that it was an electoral event. Among India's 200 million Muslims, already worried after an increase in inter-religious tensions, many are watching the event with apprehension.
Mohammed Shahid, a Muslim, 52, recalls how his father was burned alive by a Hindu mob during the violence that broke out in the city more than three decades ago. For me, the temple symbolizes nothing other than death and destruction, he said.