Iran's foreign minister has been replaced by the head of the country's nuclear programme, in a move that is being seen as the strengthening of the position of President Ahmadinejad and an indication of a tougher public stance towards the global community.
Manoucher Mottaki was fired while visiting Senegal without any prior indication that his job was under threat.
Analysts say that the change suggests intrigue at the highest echelons of the theocratic state, in the ongoing factional power struggle in Tehran.
In a brief statement on his website, Mr Ahmadinejad gave no explanation for the change. But Mr Mottaki is seen as being close to Supreme Leader Ayatollah Ali Khamenei. According to sources, the President has sought for some time to bring in someone who was more personally loyal to him, as he attempted to bolster his authority.
The nuclear chief, Ali Akbar Salehi, is one of Ahmadinejad's 12 vice presidents. He takes up his new position as Iran's most senior diplomat as Tehran resumes critical talks with world powers over a nuclear programme that has brought four rounds of UN sanctions.
"This move shows not only the internal tensions, but the primacy of the nuclear issue as Iran's main foreign policy objective," said Rasool Nafisi, an expert on Iranian affairs at Strayer University in Virginia. In the past year, Mr Mottaki opposed a decision by President Ahmadinejad to appoint his own special foreign envoys to key areas such as the Middle East, Afghanistan and the Caspian Sea region.
Mr Mottaki held that the appointments were an embarrassment to the foreign ministry and allegedly took his complaint to Ayatollah Khamenei, who sided with the minister, forcing the President to back down.
Mr Ahmadinejad has challenged the supreme leader in the past over some political appointments. Last year, the president tried to resist Ayatollah Khamenei's order that he fire one of his vice-presidents opposed by conservatives, though Ahmadinejad finally caved in and removed him.
Iranian media have also reported in the past year that some MPs were pushing for Mottaki to be dismissed, arguing that he failed to adequately defend Iran internationally, such as at the UN.
It was not immediately clear how long Mr Salehi – who has a doctorate in nuclear physics from Massachusetts Institute of Technology – would remain in the caretaker role. The semi-official Fars news agency says Mohammad Ghannadi, a prominent nuclear scientist, is expected to replace Salehi as the new nuclear chief, an indication that Mr Ahmadinejad wants him to keep the job permanently.
Mr Ghannadi is currently Salehi's deputy at the Atomic Energy Organization of Iran. Mr Salehi – or any other candidate for the foreign ministry – has to win a vote of confidence from the 290-seat parliament to be appointed to the position.
Prominent conservative MP Alaeddin Boroujerdi says he was stunned to hear the news, saying the parliament was not aware of Ahmadinejad's decision to dismiss Mottaki, according to the khabaronline.ir news website. Another conservative MP Mahmoud Ahmadi Biqash, said: "It's unpleasant that he is fired in the middle of a foreign assignment. The president should have waited for Mottaki to return home first before [naming] a replacement."
German Foreign Minister Guido Westerwelle said Mottaki's dismissal should not affect the nuclear talks, which should continue regardless of the officials involved.