(CNN) -- Standard & Poor's downgraded Spain's debt to a "AA" rating Wednesday, down from "AA+," a day after its downgrading of Greek debt set off falls in markets worldwide.
Spain's economy is among the largest in the European Union, significantly bigger than Greece's.
The S&P announcement came as German Chancellor Angela Merkel huddled with the head of the International Monetary Fund to hammer out specifics of aid to Greece.
Germany will do what it can to help Greece out of its financial crisis, Merkel said Wednesday, "but also Greece has to do its part."
"Obviously what Greece has to do is a difficult thing, but I think they are committed to doing it," IMF head Dominique Strauss-Kahn said in an appearance with the German leader.
The specifics of international aid to Greece have not yet been finalized, he said later.
"While the IMF is negotiating with a country we can't give too much about what is going on," he said. "Until we reach this point there is no precise information to give because the information doesn't exist."
Standard & Poor's downgraded Greece's debt rating to junk status Tuesday, setting off shocks in global markets and raising fears for the stability of the euro.
Greece is the first European country to fall below investment grade.
It was Greece's second downgrade in two weeks and a major problem for Athens as it struggles to crawl out from beneath the country's massive debt.
The national debt of 300 billion euros ($394 billion) is bigger than the country's economy, and some estimates predict it will reach 120 percent of gross domestic product in 2010.
Sixteen nations across Europe use the euro as their currency.
Merkel and Strauss-Kahn said the stability of the eurozone was critical.
"We need to go fast because the situation is... serious" for Greece, for all the eurozone now, Strauss-Kahn said.
He said not to expect an immediate fix to the problem.
"It will take time," he admitted.
He said the aid program to Greece was a responsible investment.
"It's not granting money, it's loans that will be repaid when Greece is back on track," Strauss-Kahn said, later adding, "There is no program from the IMF that hasn't been repaid in the past."
The Greek government has already started slashing spending and implemented some austerity measures as a way to reduce its massive debt, and it is expected to announce new measures in the coming weeks.
Greek civil servants and private sector workers said they are planning a 24-hour strike May 5 to protest government austerity measures, the unions announced Wednesday.
Last week, Greece announced it would finally tap a $53-billion bailout plan sponsored by the European Union and the International Monetary Fund.
Strauss-Kahn and Jean-Claude Trichet, president of the European Central Bank, were in Berlin, Germany, Wednesday trying to persuade the German parliament to approve its proposed share of that plan, totaling $11 billion.
Merkel's government is under international pressure to put forward the money, but with state elections scheduled for the next few days, it is also facing pressure at home to hold back.
S&P's junk rating now makes it much more difficult and expensive for Greece to try to raise money and debt in world markets.
While the agency lowered its long-term sovereign credit rating on Spain, it reaffirmed its "A-1+" short-term sovereign credit rating for the country.
"The outlook is negative," S&P said in a statement. Its "transfer and convertibility assessment is unchanged at 'AAA,'" it said.