World leaders denounced Thursday's bombings in Madrid as a barbaric assault on Spanish democracy and urged nations to cooperate in bringing those responsible to justice and preventing terrorism.

Sympathy poured in from capitals worldwide, led by Spain's partners in the European Union (search).

"There is a general election due in Spain on Sunday. What happened today is a declaration of war on democracy. Let Sunday show that Spanish democracy is determined to overcome terrorism," European Parliament President Pat Cox said.

European Commission President Romano Prodi called the attacks "ferocious and senseless."

"This is not a political act, it is a criminal act against defenseless people ... a perverse act of terrorists," he said.

The United States, Britain and Russia emphasized the attacks demonstrated the need to toughen international resolve against terrorist organizations.

President Bush was one of several leaders who spoke by telephone with Spanish Prime Minister Jose Maria Aznar (search). Dozens of other world leaders sent letters of condolence.

"I appreciate so very much the Spanish government's fight against terror, their resolute stand against terrorist organizations like the ETA, and the United States stands with them," Bush told reporters.

Spanish officials initially blamed the Basque separatist group, but a claim of responsibility was later reportedly issued in the name of the Al Qaeda (search) terrorist network.

British Prime Minister Tony Blair — who along with Aznar strongly backed the U.S.-led invasion and occupation of Iraq — said the Madrid bombings "underline the threat that we all continue to face from terrorism."

The U.N. Security Council condemned the attacks and urged all nations to cooperate in bringing the bombers to justice.

Secretary-General Kofi Annan said the killing of innocent people can never be justified and expressed hope that "the perpetrators will be brought to justice swiftly."

Russian President Valdimir Putin, who also telephoned Aznar, wrote in a condolence message to Spanish King Juan Carlos: "This senseless, barbaric action has again shown that the world community must even more resolutely combat terrorism. Today, as never before, the entire civilized world must unite in the fight against this evil."

The news dampened stock markets worldwide, most severely in Europe, where benchmark indexes suffered their biggest falls in months. The New York markets also opened sharply lower but quickly reversed course.

World leaders stressed they shared Spain's pain and fury.

Irish Justice Minister Michael McDowell, whose country holds the rotating EU presidency, said the attacks were "perpetrated by cowards who are morally and ethically bankrupt."

Italian President Carlo Azeglio Ciampi denounced the attacks as "abominable violence" and said they would promote European unity against terrorism.

In Berlin, Chancellor Gerhard Schroeder said he was "deeply dismayed by this inhuman attack." His government offered to send in investigators.

President Jacques Chirac of France wrote in a letter to Aznar, "In these horrifying circumstances, I extend in my name, and in the name of the French people, my most sincere condolences."

In Tokyo, Japanese Foreign Minister Yoriko Kawaguchi called the attacks "unforgivable."

Pope John Paul II called the attacks abominable.

"The Holy Father reiterates his firm and absolute disapproval of such actions that offend God, violate the fundamental right to life and undermine peaceful coexistence," said a message sent from the Vatican to Spanish church authorities.

The secretary-general of the Arab League, Amr Moussa, said the 22-nation association "condemns such terrorist acts that aim at killing innocent civilians."

Political representatives of the Irish Republican Army, which traditionally backs ETA's campaign, also condemned the attacks.

"This is an appalling act. It is wrong and those involved should stop," said Gerry Adams, leader of the IRA-linked Sinn Fein party.

Condemnation was particularly heartfelt in the Spanish-speaking nations of Central and South America.

"The intimate ties that unite us with Spain make us feel as our own the losses that have occurred in that nation, so close to our heart," said Mexican President Vicente Fox.

President Fidel Castro of Cuba sent a letter of sympathy to the king and Venezuela declared several days of national mourning. In Chile, President Ricardo Lagos predicted Spain's population would prove resilient.

"Our Spanish friends will have to react the way they know — with the unity of the people. We should not let ourselves be intimidated," Lagos wrote to Aznar.