This week journalists mourn the death of Apple Daily and all it stood for — a free and rambunctious Hong Kong, the last beachhead of uncensored speech in China. For 26 years, the paper celebrated Hong Kong’s distinct identity and political culture and warned against China’s homogenising and controlling impulses.

On Wednesday night, the staff put its final edition to bed, after the government, citing a new national security law, froze its assets and jailed its top executives. It was one more reminder that “one country, two systems”— the governing principle China and the United Kingdom had agreed upon before Hong Kong’s turnover in 1997 — was now just one country, one system.

To Asian journalists, this was another warning that even the most financially robust and popular news media may not survive the region’s authoritarian resurgence. Last year, ABS-CBN, the Philippines’ largest and most profitable broadcaster, was forced to shut down, denied a new franchise after it incurred President Rodrigo Duterte’s ire.

After Myanmar’s military coup in February, scores of journalists were jailed and many others forced underground. In Thailand, where anti-government protests erupted last year, an emergency decree bans news that incites fear. Elsewhere, laws against fake news and cyber crime have muzzled reporting.

Founded by the entrepreneur Jimmy Lai, Apple Daily had long been a thorn on China’s side. The paper was often sensational and sometimes wrong, but it had a feel for the pulse of one of the most vibrant cities in the world. It delighted in thumbing its nose at Beijing, asserting that Hong Kong has flourished because of its laissez-faire capitalism, freewheeling politics and openness to the world.

Lai embodied the city’s entrepreneurial flair and boldness of thought. His rags-to-riches story mirrored Hong Kong’s own. A refugee from communism, he found work in a sweatshop in Hong Kong and eventually set up the international clothing retailer Giordano. His outspokenness would ultimately cost him his company. Instead, he built a thriving media business by being the pebble in the shoe of Chinese power.

The late nineties and early aughts were a propitious time for muckraking in many parts of Asia. Authoritarian regimes were being dismantled; press controls, loosened; and citizens were hungry for information. Muckrakers were exposing corruption, environmental blight, the abuse of power and the imperviousness of states to the health and safety of their citizens.

Then came the backlash. Freedom monitors began to see a rise in “soft censorship” and a decline in global freedom beginning in 2006. In Hong Kong and elsewhere, authorities used advertising boycotts, regulatory harassment and financial pressures to clamp down on critical reporting even as they maintained the fiction of press freedom.

Today the gloves are off. States have become bolder and more sophisticated in muzzling the media, including by unleashing troll armies and flooding the public sphere with disinformation. The recent decline in media freedom has been precipitous, and the usual defensive tactics — protests, petitions, Western condemnation — far less effective.

Journalists are often the first target of autocratic attacks. They are canaries in the mine, signalling that democracy is under existential threat. In Hong Kong, citizens realise that clamping down on journalists curtails their own rights as well. This is why they kept vigil outside Apple Daily’s office and queued for hours to get copies of the paper’s last edition.

“Hong Kong was a beacon of freedom. My primary school teachers taught me to be proud of our rights: the freedom of speech, freedom to protest, and freedom of the press,” a young journalist there told me. “It’s hard to accept that city no longer exists.”

“There were so many things I took for granted growing up in Hong Kong,” said another. “Hong Kong was the only place on Chinese soil where people could gather to remember the Tiananmen massacre.”

A journalist who reported on the paper’s closure said: “Two decades of online news archives by one of the city’s biggest and most comprehensive news outlets vanished within an hour when Apple Daily shut down.” Even more frightening, she said, was the loss of the ability to speak free from fear.

Hong Kong’s journalists were the keepers of China’s memory of the struggle for democracy. In autocracies around the world, journalists, by recording history and standing up to power, sustain the memory of freedom. They fire up the democratic imagination, hoping to keep the darkness at bay.

The author is one of the founders of the Philippine Center for Investigative Journalism and a professor at Columbia University