Spain resisted mounting pressure over its debts on Wednesday after Moody's joined other big credit raters in downgrading its sovereign rating, damaged by the eurozone finance crisis.
Moody's cut Spain's rating by two notches from A1 from Aa2, with a negative outlook, "to reflect the downside risks from a potential further escalation of the euro area crisis."
The Spanish government challenged the move, with one economy ministry official saying it was "contradictory" after Moody's had welcomed a constitutional deficit-cutting measure Spain introduced last month.
Spain's Treasury added in a statement: "This rating action may be motivated more by a short-term reaction to negative news about the eurozone debt markets than by an analysis of Spain's medium- and long-term fundamental outlook."
The downgrade came days after a similar move from Standard & Poor's, which last week cut Spain's sovereign rating from AA to AA-minus, with a negative outlook. Fitch Rating slashed Spain's rating by two notches earlier this month.
Describing a now familiar malaise of slow growth and crushing private and public debt, Moody's in effect issued a vote of no confidence in Spain and the European Union's handling of the crisis so far.
"The already moderate growth prospects for Spain have been scaled back further in view of the worsening global and European growth outlook," Moody's warned in its downgrade note.
"Spain's large sovereign borrowing needs as well as the high external indebtedness of the Spanish banking and corporate sectors render it vulnerable to further funding stress."
"We do not agree" with the downgrade, said the Spanish economy ministry official, who asked not to be named.
"Their main argument concerns instability at a European level, so it is surprising that the agency did not wait a few days to see the solution" offered by EU leaders at a summit this weekend, the official told AFP.
"The nation's significant deleveraging has significantly reduced its external financing needs," the Treasury statement added. "The Spanish government remains committed to fiscal consolidation and structural reform."
Spain has suffered from the global financial crisis and the bursting of a domestic housing bubble in 2008. Unemployment is at more than 20 percent and big spending cuts are hitting healthcare and education.
It holds an early general election on November 20 in which the ruling centre-left government is widely expected to be chased out by the conservative opposition.
Moody's forecast economic growth of "one percent at best" in 2012, compared with earlier forecasts of 1.8 percent, saying Spain, in particular its regional authorities, would struggle to meet targets for lowering the deficit.
Moody's has also downgraded the debt of Italy and Belgium over similar concerns.
Analysts warned the hardship could worsen if EU leaders, meeting at summit on Sunday after two days of EU and eurozone talks, fail to end a debt crisis which is undermining the stability of the euro.
"If no solution is reached, Spain could suffer," said Jesus Castillo, a southern Europe analyst at Natixis bank.
"There will be stronger pressure from the markets and therefore higher financing costs which lead to a weakening of its financial situation."