SINGAPORE - The euro was pinned at a 20-year low on Friday, licking its wounds at the end of its worst week in two months as investors braced for Europe to tip in to recession, while markets awaited U.S. jobs data to set the next direction for the dollar.

The euro is down more than 2% this week on fears that gas shortages loom in Europe and economic growth will suffer.

It hit a two-decade trough of $1.0144 overnight and is barely clinging on above parity, last buying $1.0185.

The euro's slide has vaulted the U.S. dollar index to a two-decade high of 107.270 this week, and the index was last just below that level and down 0.1% in Asia at 106.840.

"Europe is exposed to large risks around energy dependency, a cost of living crunch on the consumer, and fragmentation risk. This spells euro/dollar lower," said analysts at Citi.

The Australian dollar rose 0.3% on Friday to $0.6850, scraping from a two-year low of $0.6762, with help from a infrastructure-led stimulus program announced in China that traders hope will boost demand for raw materials.

Sterling also looks set to have navigated a week of British political chaos relatively well. It is down 0.3% on the week, but bounced a bit overnight when Prime Minister Boris Johnson quit, ending uncertainty about his future.

The pound last bought $1.2053 and was on course for its best week in more than two years on the ailing euro.

The New Zealand dollar rose 0.3% to $0.6192 and looks set for a steady week.

Growing unease at the world's economic outlook has steadied a sliding Japanese yen, as investors look for safety, and it held at 135.94 per dollar.

While surging energy prices look to take the wind out of confidence and growth in Europe, investors have also been worried about the U.S. economy, even though the most recent data has been better than expectations.

U.S. non-farm payrolls figures are the next indicator, due at 1230 GMT, with economists forecasting some 268,000 jobs were added in June.

A stronger figure could allay some recession worries, but would probably add to rate hike bets and could lift the dollar. "Stronger payrolls gains would underpin expectations for an ever more aggressive Fed policy stance," said Commonwealth Bank of Australia strategist Carol Kong in Sydney.

Deutsche Bank strategist Alan Ruskin also said that merely meeting expectations would be enough to contribute to talk of "'U.S. exceptionalism' in the face of a global energy shock." That can keep the dollar well bid, "with euro/dollar parity the most obvious multi-day/week target," he said.

The dollar has also been standing tall in emerging markets, driving several Asian currencies to multi-year lows this week and India's rupee to a record trough.

Bitcoin has mounted a semblance of recovery, meanwhile, gaining nearly 15% on the week to $22,100.

(Reporting by Tom Westbrook. Editing by Sam Holmes)