Since then, liberal Chinese academics and writers have become increasingly marginalized, and denied chances to lecture or publish. Publications, groups and websites that served as platforms for unorthodox views have closed or retreated to safer topics.

In 2016, loyalist party officials took control of Yanhuang Chunqiu, a monthly history magazine that had been a flagship for liberal intellectuals and retired officials. In 2013, the Transition Institute, another adventurous think tank in Beijing, was shut by the government; its founder, Guo Yushan, was detained in 2014 and held for nearly a year.

So far, Unirule has escaped that fate. But its survival has become increasingly tenuous.

The institute was forced out of larger offices in October, and this year its main websites and social media accounts in China were shut by regulators, making it difficult for Unirule to publicize its ideas. (It now runs a website accessible in China only if readers have software to creep past internet censorship barriers.)

Unirule has remained alive by focusing on economic policy debates that are less threatening to the government than bluntly political topics. It has also been protected by the prestige of its founder, Mao Yushi, an 89-year-old economist.

“Our survival is a testament to China’s development of rule of law,” said Jiang Hao, a law and public policy researcher who works for Unirule. “China is making a transition from arbitrary rule to rule of law, and we’re an example of that.”

Mr. Mao and other scholars founded the Unirule Institute in 1993 as a vehicle for promoting market reforms, stronger private property rights, rule of law and other liberal ideas.

But it and other outposts of liberal democracy in China came under deepening pressure even before Mr. Xi rose to power.