Philippines' President Rodrigo Duterte declared his "separation" from longstanding ally the United States in Beijing on Thursday, as he re-balances his country's diplomacy towards China.
"I announce my separation from the United States," he said to applause at a meeting in the Chinese capital.
His comments came after he met his Chinese counterpart Xi Jinping at the Great Hall of the People on Tiananmen Square, with the two men pledging to enhance trust and friendship, while playing down a maritime dispute.
The two leaders -- Duterte donning a suit and tie for the occasion -- strode side-by-side down the red carpet inspecting an honor guard, with children cheering.
Xi called the two countries "neighbors across the sea" with "no reason for hostility or confrontation", the official Xinhua news agency said.
Duterte is in China for a four-day trip seen as confirming his tilt away from Washington and towards Beijing's sphere of influence -- and its deep pockets.
Under Duterte's predecessor Benigno Aquino the two countries were at loggerheads over the South China Sea -- where Beijing has built a series of artificial islands -- but since taking office in June the new head of state has changed course.
The two leaders held "extensive" and "amicable" official talks and oversaw the signing of 13 bilateral cooperation documents on business, infrastructure, and agriculture, among other fields, Chinese foreign ministry spokeswoman Hua Chunying said, without giving details.
In a statement, the foreign ministry cited Xi as telling Duterte their emotional foundation of friendly good neighborliness was unchanged, and difficult topics of discussion "could be shelved temporarily".
Duterte called the meeting "historic", it added.
Duterte's visit to Beijing capped a series of recent declarations blasting the US and President Barack Obama.
- 'Candid and friendly' -
Addressing the Filipino community in Beijing Wednesday, the firebrand leader said the Philippines had gained little from its long alliance with the US, its former colonial ruler.
"Your stay in my country was for your own benefit. So time to say goodbye, my friend," he said, as if addressing the US.
He also repeated his denunciation of Obama as a "son of a whore".
China, he said earlier, was "good". "It has never invaded a piece of my country all these generations."
Duterte has also suspended joint US-Philippine patrols in the strategically vital South China Sea, and has threatened an end to joint military exercises.
The South China Sea is of intense interest to Washington and it has repeatedly spoken out on the various territorial disputes between China and its neighbors over the waters.
Tensions have risen between the US and China over Washington's so-called "pivot" to the Asia-Pacific, a move that Beijing says is intended to contain it.
In 2012, China seized control of Scarborough Shoal, a fishing ground in the Philippines' exclusive economic zone.
In a case brought by Aquino, the Philippines won a resounding victory at an international tribunal earlier this year over Beijing's extensive territorial maritime claims in the area, infuriating the Asian giant.
But Duterte, who took office in June shortly before the tribunal ruling, has made a point of not flaunting the outcome.
Asked whether the leaders had discussed the South China Sea, the foreign ministry's Hua said they had a "candid and friendly exchange of views on how to resolve relevant disputes".
Their meeting represented a "return to the right track of dialogue and consultation" she said, adding China was willing to make "relevant arrangements" to cooperate on fishery issues.