When China rolls out the red carpet for Donald Trump, the grandeur of its welcome for the larger-than-life American president will mask a sobering reality.

President Xi Jinping, China's most powerful figure in a generation, is elevating his nation as a global power. Trump is unpopular and untrusted, pursued by political scandal and questions over his temperament as commander in chief of the world's most formidable military.

As they compete over shaping the future of the world's most populous and fastest-growing economic region, the stakes have never been higher.

On Wednesday, Trump begins what Chinese officials are billing as a “state visit plus” to Beijing, the highest-profile stop of his five-nation swing through Asia. He'll be seeking Chinese action to rebalance trade with the U.S. and to increase pressure on North Korea. Both presidents will then travel to Vietnam and the Philippines for regional summits, where they will bid for support among the continent's wavering leaders.

Trump is at a distinct disadvantage against Xi.

Xi two weeks ago consolidated his grip over China when he was endorsed for a second five-year term as communist party leader. His philosophy was enshrined in the constitution, arguably making him China's most powerful leader since Mao Zedong in the 1970s.

Donald Trump's international Presidential trips Show all 22 1 /22 Donald Trump's international Presidential trips Donald Trump's international Presidential trips French President Emmanuel Macron and US President Donald Trump AFP/Getty Images Donald Trump's international Presidential trips French President Emmanuel Macron and US President Donald Trump talk as they leave the Army Museum at Les Invalides in Paris AFP/Getty Images Donald Trump's international Presidential trips German Chancellor Angela Merkel and US President Donald Trump arrive for the group photo at the G7 Taormina summit on the island of Sicily in May 2017 Getty Images Donald Trump's international Presidential trips Mr Trump was pressed on the subject at the G7 summit in Italy Getty Donald Trump's international Presidential trips US President Donald Trump gives a speeech at the Warsaw Uprising Monument on Krasinski Square Getty Donald Trump's international Presidential trips US President Donald Trump and Britain's Prime Minister Theresa May during a ceremony at the NATO headquarters before the start of a summit in Brussels, Belgium Reuters Donald Trump's international Presidential trips Montenegro's Prime Minister Dusko Markovic is seen to the right of Donald Trump at a Nato summit in Brussels REUTERS Donald Trump's international Presidential trips Pope Francis meeting with US President Donald J. Trump EPA Donald Trump's international Presidential trips Pope Francis poses with US President Donald Trump and First Lady Melania Trump AFP/Getty Images Donald Trump's international Presidential trips US President Donald Trump arrives at Palazzo del Quirinale ahead of the meeting with Italian President Sergio Mattarella Ufficio Stampa Presidenza della via Getty Donald Trump's international Presidential trips US President Donald Trump is seen during a joint press conference with the Palestinian leader at the presidential palace in the West Bank city of Bethlehem AFP/Getty Images Donald Trump's international Presidential trips Palestinian president Mahmoud Abbas meets US President Donald Trump PPO via Getty Donald Trump's international Presidential trips Israeli Prime Minister Benjamin Netanyahu speaks with US President Donald Trump prior to the President's departure GPO via Getty Images Donald Trump's international Presidential trips US President Donald Trump and Israel's Prime Minister Benjamin Netanyahu shake hands after delivering a speech at the Israel Museum AFP/Getty Images Donald Trump's international Presidential trips US President Donald Trump and First Lady Melania Trump lay a wreath in the Hall of Remembrance as White House senior advisor Jared Kushner and Ivanka Trump watch on during a visit to the Yad Vashem Holocaust Memorial museum AFP/Getty Images Donald Trump's international Presidential trips US President Donald Trump visit to Yad Vashem Holocaust museum in Jerusalem accompanied by Prime Minister Benjamin Netanyahu GPO via Getty Images Donald Trump's international Presidential trips US President Donald Trump takes his seat before his speech to the Arab Islamic American Summit in Riyadh in Saudi Arabia Reuters Donald Trump's international Presidential trips Saudi Arabia's King Salman bin Abdulaziz al-Saud, US President Donald Trump and US First Lady Melania Trump look at a display of Saudi modern art at the Saudi Royal Court in Riyadh AFP/Getty Images Donald Trump's international Presidential trips US President Donald Trump and Saudi Arabia's King Salman bin Abdulaziz al-Saud take part in a signing ceremony at the Saudi Royal Court in Riyadh AFP/Getty Images Donald Trump's international Presidential trips King Salman presents Donald Trump with The Collar of Abdulaziz al-Saud Medal at the Royal Court Palace on 20 May AP Donald Trump's international Presidential trips US President Donald Trump is welcomed by Saudi King Salman bin Abdulaziz al-Saud upon arrival at King Khalid International Airport in Riyadh AFP/Getty Images Donald Trump's international Presidential trips U.S. President Donald Trump and first lady Melania Trump walk on the South Lawn prior to their first foreign trip Getty Images

Trump congratulated Xi for his “extraordinary elevation” and compared the status of the Chinese president to that of a king — unusually fulsome American praise for an autocrat.

Although questions remain over Xi's stewardship of the Chinese economy — he faces rising debt and an inefficient state sector — he's won popular domestic support for a counter corruption drive in the ruling party and gained effective control over disputed areas of the South China Sea through a massive island-building campaign opposed by Washington.

“As Trump heads to China, he will find Xi at the pinnacle of his power with some significant home court advantages,” said Mira Rapp-Hooper, a senior research scholar at Yale Law School.

Xi has big ambitions, too, having told the party congress it is now time for China to take center stage as a world power.

“There's clearly a confidence that extends from his newly secured position and permeates into the foreign policy realm,” Rapp-Hooper said.

As for Trump, nine months into his presidency, he has alarmed strategists in Asia with his “America First” doctrine. He opposed the universally supported Paris agreement to combat climate change, adopted a protectionist stance on trade and raised doubts over his ability to manage a security crisis by vacillating between threats and conciliation toward North Korean leader Kim Jong Un.

The Republican Trump is also carrying a lot of domestic baggage.

While Xi is lauded like a demigod in China's fawning, state-run media, Trump is buffeted by a free press and criticism from both Democrats and Republicans. His approval ratings — around 38 percent, according to Gallup — suggest he's the most unpopular new U.S. president in the history of modern polling.

Reviled by political rivals, he has faced repeated and increasingly acrimonious run-ins with senior members of his own party who have been outraged by his freewheeling use of Twitter, off-the-cuff interview style and penchant for personally attacking those who cross him. Tennessee Sen. Bob Corker, a leading foreign policy voice, recently argued that Trump “debases our nation” with constant untruths and name-calling, accusing the president of setting the U.S. “on the path to World War III.”

More immediately, perhaps, a legal net is closing on former Trump associates as the FBI investigates allegations of collusion between his campaign and Russia during the 2016 presidential election. A former campaign adviser pleaded guilty last week to lying to the FBI in a criminal case that pushed the investigation closer to the president.

Trump denies any collusion. And predictably, he maintains that he's in Asia “with great negotiating strength because of our tremendous economy.” The latest U.S. jobs report showed unemployment at a 17-year low and the stock market at a record high.

Kurt Campbell, a former top U.S. diplomat for Asia and architect of President Barack Obama's strategic “pivot,” said domestic woes will shadow Trump on his travels to the region, where the conventional wisdom is of U.S. retrenchment during “a period of dramatic Chinese advancement.”

Nations are likely to “skate a little closer to Beijing,” Campbell said.

However, Thitinan Pongsudhirak at Thailand's Chulalongkorn University said Trump has clawed back U.S. influence in Southeast Asia after Obama's human rights criticism pushed some American allies closer to Beijing. With authoritarian leaders in Thailand and the Philippines, in particular, Trump has repaired ties.

But the Trump administration hasn't helped itself elsewhere with its mixed policy signals, veering from America-centric economic nationalism to more traditional expressions of U.S. engagement in Asia. Recently, Washington outlined a strategy of building ties with democracies across the “Indo-Pacific.”

The idea is similar to the Obama pivot that Beijing always viewed as a China containment policy. The Chinese would prefer the two countries accommodate each other's interests. It may view the close personal relationship between Trump and Xi as the best way toward that relationship.

“I don't think anyone would be able to contain China,” Cui Tiankai, China's U.S. ambassador, told reporters in Washington last week.