China says the oil rig that sparked a major diplomatic row with Vietnam by drilling in disputed waters has finished work and is being removed.
In a statement, China National Petroleum Corp (CNPC) said it would now assess the data collected by the rig.
China moved the rig into waters near the Paracel Islands – which Vietnam also claims – in May.
The row over the rig led to clashes between ships from the two nations and major anti-China riots in Vietnam.
Vietnam’s coast guard told Reuters news agency that the rig was now moving away towards China’s Hainan island.
Coast Guard Chief of Staff Admiral Ngo Ngoc Thu said the rig had been moving since late on Tuesday. A senior fisheries official also confirmed that the rig was under way.
The news that the rig was moving came in a CNPC statement carried by China’s state-run Xinhua news agency.
“Signs of oil and gas were found in the operation,” Xinhua quoted the statement as saying, and CNPC “will assess the data collected and decide on the next step”.
China moved its Haiyang Shiyou 981 oil rig into South China Sea waters west of the disputed Paracel Islands in early May, an action the US described as “provocative” and “aggressive”.
Government ships from China and Vietnam then clashed there on several occasions, bumping and exchanging water cannon fire as Vietnam sought to block Chinese drilling operations.
Vietnam also saw three days of anti-China unrest during which angry workers targeted foreign-owned factories in some areas, leaving at least two people dead and dozens injured. Several factories were burned down or damaged.
Both nations claim the Paracel islands and in 1974 fought a brief but bloody war over them.
The introduction of the rig came amid broader tensions between Beijing and South East Asian nations over the South China Sea.
China’s maritime territorial claims overlap those of several of its neighbours and in recent years it has sought to assert these claims in a more muscular fashion.
Ties with Hanoi and Manila have been particularly badly hit. The Philippines is currently taking China to an international court over the issue.
A statement by China’s Ministry of Foreign Affairs spokesman Hong Lei on the rig’s removal pointed out that “the Xisha [Paracel] Islands are integral parts of China” and that the drilling operation was in “indisputable” waters which fell within China’s jurisdiction.
China “firmly opposes Vietnam’s unjustified disruptions” to operations, he added.