He had been hospitalised for more than two months with a kidney infection and chest congestion. He had suffered a stroke in 2009, which reportedly weakened his cognitive abilities, following which he developed dementia.
In May 1998, with barely two months in office as prime minister, Vajpayee presided over the Pokhran-II nuclear tests, in which India detonated nuclear bombs in the Rajasthani desert.
But he later launched a groundbreaking peace process with Islamabad.
Vajpayee served as prime minister briefly in 1996 then again from 1998 to 2004. Manmohan Singh, who succeeded Vajpayee as PM in 2004, hailed the BJP stalwart as a great patriot and among modern India's tallest leaders who spent his whole life serving the country.
Union Home Minister Rajnath Singh and BJP President Amit Shah had visited AIIMS on August 11 to enquire about the health condition of Vajpayee. He gave the go-ahead for underground nuclear tests in 1998 believing nuclear weapons would be deterrent against China and Pakistan.
In this February 1999 photo, Pakistani Prime Minister Nawaz Sharif (left) is seen receiving Indian Prime Minister Atal Bihari Vajpayee at the Wagah border near Lahore, Pakistan.
"It was Vajpayee's exemplary leadership that set the foundations for a strong, prosperous and inclusive India in the 21st century".
In the days after the riots, Vajpayee said he could not understand how Hindus could burn women and children alive, sadly asking a group of Muslim survivors: "Have we lost our way so much that we cease to be humans?"
Modi's government presented Vajpayee as an icon, seeking inspiration from his political career and cashing in on his stature and popularity as a statesman acceptable across political divides.
The body of Vajpayee was later taken to Bharatiya Janata Party's national headquarters at Deen Dayal Upadhyay Marg. "His futuristic policies across various sectors touched the lives of each and every citizen of India", Modi tweeted Thursday. "During his tenure, Prime Minister Vajpayee advocated for a robust partnership with the United States, referring to us as "natural allies", it said.
"Former PM, Atal Bihari Vajpayee was loved and respected by millions". The government conferred the Bharat Ratna, India's highest civilian honour, on him in 2015. A state funeral would be accorded to him and a half day holiday would be observed in all central government offices on Friday.
Don't miss out on the latest news and information.