Saudi Crown Prince Mohammed bin Salman met China's President Xi Jinping on Friday and bagged a $10-billion oil deal, pressing on with his diplomatic charm offensive in Asia following a global outcry over the Khashoggi killing.
Mohammed arrived in Beijing on Thursday following visits to Pakistan and India, showing the world that his country still has allies after the grisly murder of Saudi journalist Jamal Khashoggi at the kingdom's Istanbul consulate.
"China is a good friend and partner to Saudi Arabia," Xi told Mohammed in a meeting in the Great Hall of the People.
"Saudi Arabia's relations with China can be traced back a very long time in the past," the crown prince said.
"Over such a long period of exchanges with China, we have never experienced any problems with China."
He met with Chinese Vice Premier Han Zheng earlier on Friday.
"Is the crown prince's tour symbolic of Saudi Arabia's pivot to the East? Yes," Najah al-Otaibi, a senior analyst at the pro-Saudi think-tank Arabia Foundation, told AFP.
"Riyadh wants to strengthen alliances in Asia -- especially now with the continuing fallout with the United States over Khashoggi's murder and other issues, and attempts by the EU to put Riyadh on a blacklist over money laundering allegations."
Khashoggi, a fierce critic of the prince, was killed at the Saudi consulate in Istanbul in October, a murder that tarnished the image of the kingdom and of the crown prince in particular.
Riyadh initially denied the murder, then gave several conflicting accounts of Khashoggi's death, and now claims he was killed in an unauthorised operation that did not involve Mohammed.
The murder sparked global indignation, with US lawmakers pushing for Washington to distance itself from the crown prince, but the White House has maintained close relations with Riyadh, a major ally in the Middle East.
Separately, the European Commission wants to add Saudi Arabia to a money-laundering blacklist of governments that do too little to thwart the financing of terrorism and organised crime.
But China is looking to strengthen its economic ties with the kingdom, as Beijing pursues its ambitious Belt and Road trade infrastructure initiative, while Riyadh rolls out "Saudi Vision 2030" -- the crown prince's major programme to diversify the national economy away from oil.
Mohammed told the Chinese President they could join the two projects "to realise more progress and jointly confront challenges".
Vice Premier Han suggested during his meeting with the crown prince that the two countries deepen partnerships in energy, infrastructure construction, finance, and high-tech.
- Trade and security -
Riyadh's national oil giant Saudi Aramco said it had signed an agreement to form a Saudi-Chinese joint venture -- worth more than $10 billion -- to develop a refining and petrochemical complex in northeastern Liaoning province.
The Saudi Arabian General Investment Authority also announced the signing of 35 non-binding memorandums of understanding, including deals related to energy, mining, transportation and e-commerce.
China is Saudi Arabia's largest trading partner.
"As the kingdom diversifies its non-oil economy, it needs a variety of other investors with technical expertise, including the Chinese," Otaibi said.
"China steadfastly supports Saudi Arabia pushing a diversification of its economy and societal reforms," Xi told Mohammed, according to state broadcaster CCTV, adding he supported the hard work the kingdom has undertaken to promote stability and safety at home.
National security is a potential area of cooperation between the Gulf state and China.
The two countries should boost partnerships in counterterrorism and law enforcement, and exchange experience on combating extremism, Han said in his meeting with Mohammed, according to a report by the official Chinese news agency Xinhua.
The Saudis said they "firmly supported" Beijing's efforts to keep the country secure, and opposed "interference by external forces in China's internal affairs", Xinhua added, paraphrasing remarks by the crown prince.
Riyadh has remained silent over China's treatment of Uighurs and other mostly Muslim minorities in the far-western region of Xinjiang.
Up to one million Uighurs and other minorities are being held in internment camps in Xinjiang as part of a draconian anti-terror and anti-separatist campaign, according to estimates cited by a UN panel.
"China has the right to take anti-terrorism and de-extremization measures to safeguard national security," Mohammed told Xi, according to CCTV.
"Saudi Arabia respects and supports it and is willing to strengthen cooperation with China," he said.