BAGHDAD, Iraq — The U.S. ambassador delivered a blunt warning to Iraqi leaders Monday that they risk losing American support unless they establish a national unity government with the police and the army out of the hands of religious parties.

Ambassador Zalmay Khalilzad delivered the warning as another 24 people, including an American soldier, died in a string of bombings, underscoring the need for the country to establish a government capable of winning the trust of all communities and ending the violence.

Such a government is also essential to the U.S. strategy for handing over security to Iraqi soldiers and police so the 138,000 U.S. troops can go home. But talks among Iraqi parties that won parliament seats in the Dec. 15 election have stalled because of deep divisions among Shiites, Sunni Arabs and Kurds.

During a rare news conference, Khalilzad said division among the country’s sectarian and ethnic communities was “the fundamental problem in Iraq,” fueling the Sunni Arab-dominated insurgency and the wave of reprisal killings.

“To overcome this there is a need for a government of national unity,” which “is the difference between what exists now and the next government,” he said. The outgoing government is dominated by Shiites and Kurds.

Khalilzad said Iraq’s next Cabinet ministers, particularly those heading the Interior and Defense ministries, “have to be people who are nonsectarian, broadly acceptable and who are not tied to militias” run by political parties.

Otherwise, he warned that “Iraq faces the risk of warlordism that Afghanistan went through for a period.”

To underscore his remarks, Khalilzad reminded the Iraqis that the United States has spent billions to build up Iraq’s police and army and said “we are not going to invest the resources of the American people and build forces that are run by people who are sectarian” and tied to the militias — some of which the ambassador said received “arms and training” from Iran.

British Foreign Secretary Jack Straw, who arrived in Baghdad late Monday, was expected to reinforce Khalilzad’s message during meetings with Prime Minister Ibrahim al-Jaafari and other Iraqi leaders.

There was no response from al-Jaafari’s government to Khalilzad’s warning, but a prominent Shiite politician, Jalaladin al-Saghir, said the comments were “unacceptable” and constituted interference in the affairs of a sovereign state.

“We all want a national unity government and the U.S. ambassador is no more eager than we are to reach such a government,” al-Saghir told The Associated Press. “It is the Americans who push toward sectarianism by their ever-changing points of view. We feel uneasy about some of the U.S. agenda.”

Al-Saghir said the Americans had installed former members of Saddam Hussein’s Baath party in the Interior and Defense ministries and “Shiites are upset about this.”

In Najaf, al-Jaafari said formation of the government was more complicated “because this time the Arab Sunnis are participating in the political process.”

In the latest bloodshed, an American soldier was killed Monday by a roadside bomb near Karbala, a Shiite shrine city about 50 miles southwest of Baghdad. The death brought to at least 2,274 the number of members of the U.S. military to have died since the beginning of the Iraq war in March 2003, according to an Associated Press count.

A suicide bomber detonated an explosives belt on a bus Monday in Baghdad’s Shiite district of Kazimiyah, killing 12 people and wounding 15, police said. Earlier, a bomb exploded next to tea stalls near Liberation Square in central Baghdad, killing at least four day laborers and wounding 14, police said.

In Mosul, 225 miles northwest of Baghdad, a suicide attacker blew himself up in a restaurant packed with policemen eating breakfast, killing at least five people and wounding 21, including 10 policemen, officials said.

The Shura Council for Mujahedeen in Iraq claimed responsibility in a statement posted on an Islamic Web site, saying one of the “lions of monotheism” attacked the restaurant because it was “frequented by apostate policemen.”

Two more civilians died when a car bomb exploded in Madain, southeast of Baghdad, police said. Eleven people, including three women, were wounded.

A coalition of Shiite religious parties won 130 of the 275 seats in the new parliament. Although they have agreed in principle to a unity government, Shiite leaders insist their strong showing in the election gives them the democratic right to control key levers of power.

A Kurdish alliance won 53 seats and two Sunni Arab blocs together took 55 seats — a major increase over Sunni representation in the outgoing parliament. Iraqis have until mid-May to form a new government, but U.S. and Iraqi officials warn the process could take longer because of political differences.

Mistrust and bitterness among the communities run deep. Much of it is rooted in oppression of Shiites and Kurds by Saddam’s Sunni-dominated regime and fanned by the current insurgency. Shiites and Kurds dominate the security services and most of the insurgents are Sunni Arabs.

Several Shiite parties are believed to control armed militias, some of which date back to the Iran-Iraq war of the 1980s when many Iraqi Shiites fled to Shiite-dominated Iran. Kurds maintain the biggest armed force — the peshmerga — which they maintain is the legitimate security force of their autonomous government in the north.

Shiites demand that Sunni Arab parties work actively against the insurgency. Sunnis insist on drawing a difference between “legitimate resistance” to foreign occupation and terrorism that targets civilians.

Kurds zealously guard the self-rule they have enjoyed since 1991, and many of them want to expand their autonomous region to oil centers around Kirkuk, claimed by Kurds, Arabs and Turkomen.