After his tenure at the helm of the LEF, Ghalibaf entered Iran’s political scene, running for the presidency in 2005. Leaked U.S. government diplomatic cables reveal speculation that the supreme leader’s son, Mojtaba Khamenei, was the “backbone” of Ghalibaf’s political campaigns. But during the 2005 campaign, Iran’s former speaker of parliament, Mehdi Karroubi, alleged that Mojtaba Khamenei persuaded his father to shift his support to Mahmoud Ahmadinejad, then mayor of Tehran, because he was more reliable than Ghalibaf. Ghalibaf lost that race, but soon after took over as mayor of Tehran after Ahmadinejad won the presidency, potentially viewing the position as a platform to pursue higher office after Ahmadinejad’s victory. Ghalibaf’s mayoral tenure was defined by infrastructural feats, including the expansion of the Tehran metro and the Sadr expressway as well as the establishment of new green spaces within Tehran. Ghalibaf even made a cameo at the World Economic Forum in Davos in 2008, and sought to distance himself from then President Ahmadinejad. In a New York Times profile, he flirted with another run for the presidency, pledging to open the country up to more foreign investment. This is when his brand as a pragmatic modernizer took shape.
But his tenure was damaged by a deadly fire, which resulted in the collapse of Tehran’s Plasco Building. Ghalibaf, who was in Qom at the time of the fire, was criticized by Iranians for not being in Tehran. Ghalibaf was also sullied by allegations of corruption concerning a donation by Tehran Municipality of 600 billion rials to a charity run by Ghalibaf’s wife. After he stepped down from the office of the mayor, members of the Tehran City Council accused Ghalibaf of billions of dollars in corruption. Despite these blemishes in his record, the supreme leader managed to find a landing spot for Ghalibaf, appointing him to the Expediency Council.
Seeking to capitalize on his management record, Ghalibaf embarked on additional runs for the presidency. In 2013, with Rouhani winning 50.7 percent of the votes, Ghalibaf came in second place with only 16.6 percent. Four years later, he ran against Rouhani again but withdrew from the race and endorsed Rouhani’s conservative challenger Ebrahim Raisi. In the 2020 parliamentary elections, Ghalibaf won big—capitalizing on low voter turnout and his reputation in Tehran by winning the most votes there. In a sign of how the electoral landscape had shifted, the most votes in Tehran went to reformist Mohammad Reza Aref in 2016.