The leaders said that a jihad would be called if foreign troops set up bases inside the country, or moved into its territorial waters.
"If any party insists on aggression, or invades the country, then according to Islam, jihad becomes obligatory," said a statement signed by 150 clerics and read out at a news conference in Sanaa, the capital.
The stark threat came as Yemeni security officials declared that the country was openly now at war with the terrorists, who are trying to carve out a haven in a country riven by rebellion, secessionism, poverty and tribal loyalties.
With some tribes accused of sheltering al-Qa'ida - many of whom are Yemeni tribesmen - a security source quoted by the defence ministry's online newspaper called September 26, warned citizens against hiding any elements of al-Qa'ida, and called on them to co-operate with the security apparatus.
The statement by the Yemeni Clerics Association, which wields considerable influence in the conservative Muslim state, seemed to be a clear attempt to limit the role Western forces can play in combating the new menace of al-Qa'ida.
The religious group includes Sheikh Abdul-Majid al-Zindani, who was once the spiritual adviser to Osama bin Laden, and who is wanted by the US and UN on terrorism charges. The Yemeni Government has refused to arrest him, saying that no proof has been given linking him to terrorism. It is also fearful of going after so influential a figure.
The US Government has said that it has no plans to deploy troops to Yemen, although Carl Levin, the chairman of the US Senate's Armed Services Committee, urged the Pentagon this week to consider targeting alQaeda with armed drones, airstrikes or even covert operations. "Most options ought to be on the table," short of a US invasion, Mr Levin said.
Sheikh al-Zindani has proclaimed publicly that the US is planning an invasion similar to that in Afghanistan and Iraq.
The clerics further whipped up fears of foreign intervention by claiming that an international conference on Yemen to be held in London later this month is meant to clear the way for a new occupation.
Yemeni officials have insisted that their troops can handle al-Qa'ida, given Western material, and are wary of putting a foreign face on their operations, fearing that it could incite a population already furious at previous US invasions of Muslim countries.