WUZHEN, China — Every year at the World Internet Conference, held since 2014 in the photogenic canal town of Wuzhen near Shanghai, companies and government officials have convened to send a message: China is a high-tech force to be reckoned with.

With that message now settled beyond much doubt, this year’s conference showcased something different. China’s tech industry is becoming more serious about grappling with its products’ unintended consequences — and about helping the government.

Discussions of technology’s promise were leavened with contemplation of its darker side effects, such as fraud and data breaches. A forum on protecting personal information featured representatives from China’s highest prosecutor and its powerful internet regulator. And several tech companies pledged their support for Beijing’s counterterrorism efforts, even as China faces international criticism for detaining and indoctrinating Muslims in the name of fighting terrorism in the western region of Xinjiang.

“Tencent has been dedicated to dealing with terrorist information online and other internet crimes, in line with the government’s crackdown,” Chen Yong, an executive in Tencent’s security management department, said at the event.

The conference, which ends Friday, also reflected some new challenges facing China. It was held at the same time as another big event: a six-day import expo in Shanghai aimed at showing China as a big buyer of foreign goods. With U.S. tariffs threatening to slow a weakening Chinese economy, the country’s leader, Xi Jinping, spoke at the expo Monday to proclaim that China could be a positive force in global trade.

At Wuzhen, by contrast, Xi appeared only by proxy. The head of the Communist Party’s propaganda department, Huang Kunming, conveyed a message of thanks from Xi and then delivered an opening address that extolled the world-changing power of internet access.

Emissaries from Silicon Valley were also in short supply. Last year, the speakers at Wuzhen included Tim Cook, Apple’s chief executive, as well as Sundar Pichai of Google. This year, the sole Western tech executive to give a keynote address was Steve Mollenkopf, chief executive of chipmaker Qualcomm.

His appearance served as a reminder of U.S. companies’ continuing travails in China, which could deepen as the two powers wrestle over high-tech supremacy. Qualcomm scrapped a $44 billion deal to buy a Dutch chip manufacturer this year after China’s antitrust authorities declined to approve it, a move widely viewed as retaliation in the trade war.

Among Chinese companies this week, private enterprises showed off the ways in which they increasingly support and work with the government, while state-backed companies demonstrated they were not doomed to be tech laggards.

The Tencent executive, Chen, described in an interview the company’s relationship with law enforcement.

Political activists have reported being followed based on what they have said on WeChat. Chat records have turned up as evidence in court, fueling speculation about whether Tencent, the app’s developer, may be the source.

Chen said Tencent reports illegal activity discovered on its platforms to the government, after which authorities can request specific user information. Metadata describing when and where users logged into a Tencent app can be stored for up to six months, he said. But Chen denied that the company gave law enforcement officials a back door through which they could freely peruse chat records and user data.

“We only store the content that the law prescribes,” he said. “However long the law says to store it, that’s how long we store it. Whatever the law says to store, that’s what we store.”

In the conference’s exhibition halls, there were lighter touches to be found. A company called Utry let loose several eager, if herky-jerky, robots that followed people around on wheels, offering to carry their bags. Kuaishou, the maker of a popular video app, demonstrated its facial-recognition prowess by scanning visitors’ faces and then, within seconds, displaying who in its vast video library most resembled them. (The results varied.)

Facial recognition is a hot area in Chinese tech, providing the technology behind both funny video selfies and smart surveillance cameras. One company attending the conference is taking things a step further.

IrisKing, which is based in Beijing and has substantial state backing, started out by making iris-recognition software for coal mines. With their faces and fingertips covered in soot, miners needed another technology for clocking in and out of work.

Now, IrisKing’s tools also help identify refugees in Syria and recover trafficked children in China, said Wang Xintao, a marketing manager for the company.

The company has also started working with the authorities in Xinjiang, Wang said. The goal? To have a database of the irises of all Xinjiang residents within two years, he said.