"The conference has thoroughly reviewed the process of dialogue and its obstacles as well as the catastrophes that afflict humanity.., and noted that terrorism is one of the most serious obstacles confronting dialogue and coexistence," the World Conference on Dialogue said in a final statement.
"Terrorism is a universal phenomenon that requires unified international efforts to combat it in a serious, responsible and just way.
"This demands an international agreement on defining terrorism, addressing its root causes and achieving justice and stability in the world."
The statement was read by Abdul Rahman Al-Zaid, the deputy secretary general of the Mecca-based Muslim World League, which organised the conference from an initiative by Saudi King Abdullah.
Representatives of Islam, Christianity and Judaism as well as other religions attended the three-day conference in Madrid aimed at bringing the great monotheistic faiths closer together.
Among them were the secretary general of the World Jewish Congress, Michael Schneider, and Cardinal Jean-Louis Tauran, who is responsible for dialogue between the Vatican and Muslims.
Tauran said the conference had "stressed the main convictions that we have in common."
The event took place against a backdrop of tensions between the Islamic world and the West since the September 11, 2001, attacks in the United States.
They range from restrictions on the use of the veil by Muslim women in some European countries to cartoons regarded as blasphemous by Muslims and the unresolved Israeli-Palestinian conflict.
The conference opened Wednesday with a speech by King Abdullah in which he called on the world’s major religions to turn their backs on extremism and embrace "constructive dialogue."
Saudi Arabia remains the only Arab Muslim country to ban all non-Islamic religious practices on its soil, even though it has a large community of expatriates professing other faiths.