http://news.bbc.co.uk/2/hi/europe/3637523.stmSpain PM orders Iraq troops home
Spain has about 1,300 troops stationed in Iraq
Spain's new prime minister Jose Luis Rodriguez Zapatero has given orders for Spanish troops in Iraq to be brought home in "as short a time as possible".
In a televised address to the nation, he said he could not ignore what he called the will of the Spanish people.
The previous government's support for the war in Iraq, and its handling of the Madrid bombings, were thought to have caused its election downfall.
Spain has about 1,300 troops stationed in south-central areas of Iraq.
Mr Zapatero said he had ordered the defence minister to "do what is necessary for the Spanish troops stationed in Iraq return home in the shortest time possible".
He spoke just hours after the new Socialist government was sworn in.
Mr Zapatero's election win last month was largely unexpected
Immediately after his election, Mr Zapatero had vowed to withdraw Spanish troops from Iraq unless they came under UN command by 30 June when their mandate expires.
His conservative predecessor, Jose Maria Aznar, sent in troops in August 2003 in a move which led to huge popular protests across Spain.
"With the information we have, and which we have gathered over the past few weeks, it is not foreseeable that the United Nations will adopt a resolution" that satisfies Spain's terms, Mr Zapatero said.
Daily attacks
The United States has condemned the decision to bring the troops home, saying it is giving in to terrorism.
Main foreign troops in Iraq
USA: 135,000
UK: 8,700
Italy: 3,000
Poland: 2,400
Ukraine: 1,650
Spain: 1,300
Australia: 850
Japan: 550
But the BBC's Danny Wood, in Madrid, says the majority of Spaniards support the decision.
Many believe the 11 March train bomb attacks were a result of the former government's support of the United States policy in Iraq, our correspondent adds.
Spanish troops play an important role in Iraq, particularly in the Shia holy city of Najaf.
Spanish troops stationed Najaf come under rifle and mortar fire almost every day from militiamen loyal to the fiery anti-US cleric Moqtada Sadr.
In November, Spain was stunned by the deaths of seven intelligence officers in Iraq, killed when their convoy came under attack outside Baghdad.
The BBC's Dominic Hughes, in Baghdad, says that with the US saying it needs thousands of extra troops on the ground in Iraq, the withdrawal of the Spanish forces will clearly be felt.