China expects to see volatile capital flows across its borders for the rest of the year because of economic uncertainty at home and abroad, the foreign exchange regulator said on Friday.

The cloudy economic environment was also likely to shrink China's trade and capital account surpluses in coming months, the State Administration of Foreign Exchange (SAFE) said.

China revised up its current account surplus for the second quarter on Friday to $50.9 billion, from a preliminary $48.2 billion. The revision was announced by the SAFE in a statement on its website.

The capital and financial account surplus in the world's second-largest economy was also revised sharply higher to $28.6 billion, from a preliminary deficit of $1.6 billion.

"As there are numerous uncertain and unstable factors within and outside the country, cross-border capital flows would continue to volatility," the regulator said.

"The surplus in balance of payments may increase, but it could also face outflow pressures."

After cooling in 12 of the last 14 quarters, China's economy is finally showing signs of stabilization, helped by an improving U.S. economy and Beijing's policy measures, which include fast-forwarding infrastructure investment.

But analysts warn investors that a recovery would be feeble and even short-lived if China keeps its promise by enacting economic reforms that impede growth in the near term.

(Reporting By Xiaoyi Shao and Koh Gui Qing; Editing by Robert Birsel)