Iran has sent 2,000 advance troops to Iraq in the past 48 hours to help tackle a jihadist insurgency, a senior Iraqi official has told the Guardian.

The confirmation comes as the Iranian president, Hassan Rouhani, said Iran was ready to support Iraq from the mortal threat fast spreading through the country, while the Iraqi prime minister, Nouri al-Maliki, called on citizens to take up arms in their country's defence.

Addressing the country on Saturday, Maliki said rebels from the Islamic State of Iraq and the Levant (Isis) had given "an incentive to the army and to Iraqis to act bravely". His call to arms came after reports surfaced that hundreds of young men were flocking to volunteer centres across Baghdad to join the fight against Isis.

In Iran, Rouhani raised the prospect of Teheran cooperating with its old enemy Washington to defeat the Sunni insurgent group – which is attempting to ignite a sectarian war beyond Iraq's borders.

The Iraqi official said 1,500 basiji forces had crossed the border into the town of Khanaqin, in Diyala province, in central Iraq on Friday, while another 500 had entered the Badra Jassan area in Wasat province overnight. The Guardian confirmed on Friday that Major General Qassem Suleimani, the head of the Iranian Revolutionary Guards' elite Quds Force, had arrived in Baghdad to oversee the defence of the capital.

There is growing evidence in Baghdad of Shia militias continuing to reorganise, with some heading to the central city of Samarra, 70 miles (110km) north of the capital, to defend two Shia shrines from Sunni jihadist groups surrounding them.

The volunteers signing up were responding to a call by Iraq's most revered Shia cleric, the Iranian-born grand ayatollah Ali al-Sistani, to defend their country after Isis seized Mosul and Saddam Hussein's hometown of Tikrit in a lightning advance this week. Samarra is now the next town in the Islamists' path to Baghdad.

"Citizens who can carry weapons and fight the terrorists in defence of their country, its people and its holy sites should volunteer and join the security forces," Sheik Abdul-Mahdi al-Karbalaie, Sistani's representative, said on Friday in a sermon at the holy Shia city of Kerbala.

He warned that Iraq faced great danger and that fighting the militants "is everybody's responsibility, and is not limited to one specific sect or group", Associated Press reported. Karbalaie's comments have consistently been thought to reflect Sistani's views.

Meanwhile, Iraqi troops had been ordered out of the northern city of Kirkuk by Kurdish fighters who have taken full control of the regional oil hub and surrounding areas, according to a mid-ranking army officer.

His account was corroborated by an Arab tribal sheik and a photographer who witnessed the looting of army bases after troops left and who related similar accounts of the takeover from relatives in the army, the Associated Press reported.

"They said they would defend Kirkuk from the Islamic State [Isis]," said the Arab officer, who oversaw a warehouse in the city's central military base.

He insisted the Iraqi troops had not planned to retreat before the Islamic State. "We were ready to battle to death. We were completely ready," he said at a roadside rest house just inside the semi-autonomous Kurdish region.

A spokesman for Kurdish forces, known as the peshmerga, said they had only moved in after Iraqi troops retreated, assuming control of the "majority of the Kurdistan region" outside the semi-autonomous Kurdish regional government.

"Peshmerga forces have helped Iraqi soldiers and military leaders when they abandoned their positions," including by helping three generals to fly back to Baghdad from the Kurdish regional capital of Erbil, said Lieutenant General Jabbar Yawar in a statement on the regional government's website.

A supporter of Maliki in the Iraqi parliament condemned the peshmerga's move, calling it a plot carried out in co-ordination with the regional government that would lead to problems.

"The Kurds have taken advantage of the current situation. They seized Kirkuk and they have other plans to swallow other areas," Mohammed Sadoun said.

A colonel from the military command responsible for Samarra said Iraqi security forces were preparing a counter-offensive against Isis on Saturday. The colonel, whom Maliki announced had been granted "unlimited powers" by the Iraqi cabinet, said reinforcements from the federal police and army arrived on Friday, according to Agence France-Presse.

The officer said the reinforcements were for a drive against areas north of the city, including Dur and Tikrit, and forces were awaiting orders to begin.

Sunni residents of west Baghdad said on Saturday Shia militias had taunted them with anti-Sunni chants. Baghdad has remained in virtual lockdown for the past three days as Isis jihadists threatened to storm the capital. However, Saturday morning saw relative normality return to deserted streets, with many residents returning to shops to stockpile supplies.

Residents offered little reaction to Barack Obama's statement late on Friday in which he appeared to condition renewed US military support on Iraqi leaders first making efforts to pull the country back from the brink. The US and Iran, foes throughout the US occupation of Iraq, share a common interest in defeating Isis, and Iran has so far expressed no opposition to US threats to send military support to Maliki.

Rouhani, asked at a televised press conference on Saturday whether Tehran could work with the US to tackle Isis, said: "We can think about it if we see America starts confronting the terrorist groups in Iraq or elsewhere. We all should practically and verbally confront terrorist groups."

Reuters reported US officials as saying there were no contacts taking place with Iran over the crisis in Iraq.

Meanwhile, the British foreign secretary, William Hague, had held talks with his Turkish counterpart, Ahmet Davutoglu, "urgently to co-ordinate approaches to the instability in Iraq and links to Syria conflict", he said on Twitter. Britain is to give £3m ($5.1m) of aid to Iraq as the first step in dealing with the humanitarian consequences of the insurgency.

The international development secretary, Justine Greening, said the initial tranche of emergency funding would allow agencies to supply water, sanitation, medicine, hygiene kits and basic household items.