Indiainfo-icon has begun withdrawing troops from a disputed Himalayan region on the border with Chinainfo-icon, foreign ministries from the two countries announced Monday, defusing a tense stand-off that had threatened to provoke armed conflictinfo-icon between the Asian rivals.

For the past two months, Indian and Chinese troops had faced off on a plateau in the Doklam area in Himalayas, after Indian troops moved in to prevent the Chinese military building a road into territory claimed by India's close ally, Bhutaninfo-icon.

China had repeatedly and furiously denounced the Indian move as a direct infringement of its sovereignty, demanded an immediate and unconditional withdrawal, and warned that conflict was a real possibility if that didn't happen.

On Monday, the two sides announced they had reached an agreement. But it was unclear if Beijing offered any concessions in return, such as agreeing to halt the construction of the road. China said it only that it would redeploy its forces according to the changing situation but would continue to patrol the area.

In a short statement, India's Ministry of External Affairs said the two countries had maintained diplomatic communication over the dispute in recent weeks.

"During these communications, we were able to express our views and convey our concerns and interests," it said. "On this basis, expeditious disengagement of border personnel at the face-off site at Doklam has been agreed to and is on-going."

China's Foreign Ministry said it was happy to confirm that all Indian "individuals and facilities" have withdrawn to the India side of the border.

Without saying so directly, Beijing implied it would now not need to keep troops permanently stationed in the area, having moved a number there in response to the Indian deployment.

"Chinese frontier defense force continues to patrol in the Doklam area," spokeswoman Hua Chunying told a regular news conference. "The situation at the spot has changed, and China will adjust and deploy according to current situation."

Hua said China will continue to "exercise its sovereign rights and maintain territorial sovereignty," in the area.

"The Chinese government values the development of a harmonious neighborly relationship with India," she said. "China hopes India will join it in maintaining border peace and stability on the basis of mutual respect, and keep the relationship developing in a healthy way."

Earlier on Monday, the state-owned China Daily newspaper had warned India stood "to face retribution" over the incident, arguing that New Delhiinfo-icon was complacent if it thought China was not prepared for military conflict if necessary.

The announcement clears the air ahead of a meeting of the "BRICS" countries in China this weekend, a bloc comprising Brazilinfo-icon, Russiainfo-icon, India, China and South Africainfo-icon.