MADRID - Spaniards were hit with another bitter dose of austerity Friday as the Cabinet approved raising the retirement age from 65 to 67 to reassure jittery markets that the country can handle its heavy debt burden.

With the European sovereign debt crisis still festering and international investors wary, Spain, like many European countries, has little option but to cut costs. The once-booming nation is struggling to crawl out of recession after its property market collapsed and its unemployment rate is above 20 per cent, a eurozone high.

The deal gave Prime Minister Jose Luis Rodriguez Zapatero a bit of breathing space as he presides over a struggling economy and trails conservatives in the polls with a general election just over a year away and local and regional elections in May.

The proposal was negotiated with unions and backed by them -- a victory for Zapatero's Socialist government.

"Hats off to the Spanish. They are setting an example," Angel Gurria, the head of the Organization for Economic Cooperation and Development, told The Associated Press on Friday. " (The deal) shows great leadership, great awareness by the Spanish about the needs, and the political courage to do it."

"It's one more success" for Europe, he said on the sidelines of the World Economic Forum in Davos, Switzerland, where many leaders and investors expressed concern about the euro and Europe's debt crises.

The plan still needs approval by Parliament, although Zapatero's Socialists have lined up support up from small regional parties to pass the measure.

The reform is complex, includes a number of sweeteners to win over union support and will be phased in very gradually starting in 2013, rather than take effect right away.

But it essentially boils down to this: once the retirement age has been increased to 67 in 2027, Spaniards will find themselves working two years longer for a full pension that will in general be smaller than what they get now.

Spain's retirement pension system is now solvent, albeit barely, but the government has warned that that will no longer be the case in a few decades' time because of rising life expectancy and a very low birth rate.

With the reform, Spain joins France and Germany in forcing people to work more years before claiming retirement benefits. France did so late last year -- raising the minimum retirement age from 60 to 62 despite a series of angry street protests -- while Germany lifted its retirement age from 65 to 67 in 2007.

Under the current system, Spaniards can retire with full benefits at 65 if they have paid into the social security system for 35 years. Under the new plan, for most people, the numbers go up to 67 and 37 years, respectively.

The new system would also change the number of working years used to calculate a retirement pension -- raising it from the last 15 years of a person's career, when presumably they earn more, to the last 25. That means, on average, a lower pension.

As a concession to unions, people will still be able to retire at 65 but only if they have chipped into the system for 38.5 years. Unions say about half the people retiring these days fit that bill.

But those people are from generations that had much less trouble finding work than people do today, particularly first-time jobseekers. The jobless rate among Spaniards aged 16 to 30 is a staggering 40 percent. Those over age 50, meanwhile, find it nearly impossible to get another job if laid off.

"If you can't find a job until you are 25 years old and it is difficult to find work after 50, I mean, who's going to be able to work 38 years? I've got a son at home who is 24 and has yet to find full-time work," said civil servant Carmen Foz, 55.

Deputy Prime Minister Alfredo Perez Rubalcaba said the pension reform plan came out of three-way talks that included Spain's main business federation. He said the plan tries to help right an economy that was booming until just a few years ago but collapsed with a burst real estate bubble and is now lagging behind as much of Europe recovers.

This deal should please investors worried that debt-laden Spain might follow Greece and Ireland in needing an international bailout, he said.

"It boosts confidence among Spaniards in general and towards our economy outside the country," he told a news conference Friday.

Labor Minister Valeriano Gomez acknowledged that if Spain's economy stays as sick as it is, young people will have a hard time putting in enough years of work to qualify for a full pension.

Ramon Castro, a 44-year-old luxury car salesman, said that could not bode well for Spain.

"Where are we headed if a generation is adrift?" he asked.