Hong Kong soccer fans turn their backs during the Chinese national anthem at the AFC Asian Cup 2019 qualification soccer match against Malaysia, in Hong Kong on Oct. 10. (AP)

BEIJING — The United States is not the only country wrestling with a controversy about free speech and respect for the national anthem. But in China, it’s the fans, not players, who are causing controversy.

Hong Kong’s soccer fans have been booing the Chinese national anthem for at least two years, an expression of popular discontent with Beijing’s interference in the affairs of the former British colony, and also of a desire to maintain a separate identity as Hongkongers.

The protests have irked China’s Communist Party, soccer’s world governing body FIFA, netizens on the mainland and even some locals.

In Beijing, China’s government responded by passing a new law in September that threatens anyone disrespecting or mocking the national anthem with 15 days’ detention, with the possibility of further criminal charges.

Hong Kong enjoys significant autonomy under the terms of the 1997 handover from British rule, but its government says it is also working on a similar law. On Monday, the city’s top official for constitutional and mainland affairs, Patrick Nip Tak-kuen, said the local version of the law would keep in mind Hong Kong’s own legal and constitutional traditions, the South China Morning Post reported.

In the United States, the National Football League is expected to decide this week whether to force players to stand for the national anthem. President Trump tweeted last week that tax breaks should be revoked for a league that disrespects “our Anthem, Flag and Country.”

Many NFL players have knelt during the national anthem in recent weeks, joining a protest against police brutality and discrimination against African Americans begun by former San Francisco 49ers quarterback Colin Kaepernick last year.

FIFA has twice fined Hong Kong’s soccer authorities over the booing, which dates back to June 2015, when the team played Bhutan in a World Cup qualifying game. That followed the 2014 pro-democracy protests in Hong Kong, known as the Umbrella Movement, several of the ringleaders of which were recently jailed.

Fans have since booed and jeered the “March of the Volunteers,” the anthem, at almost every opportunity, sometimes turning their backs as it plays or holding up signs saying “Boo” and “Hong Kong is not China.”

On other occasions, fans have chanted “We are Hong Kong,” or displayed banners saying “HK Till I Die,” “Hong Kong Power” or “Hong Kong Independence.”

The protests continued at a game against Malaysia on Oct. 10, despite the passage of the law in mainland China, the South China Morning Post reported, listing it as the 14th home match in a row where a section of fans have registered their feelings in this way.

The following day, Hong Kong’s chief executive, Carrie Lam, called it a “very serious issue.”

“Some people said: ‘Don’t boo, otherwise the next game is going to be played behind closed doors,’ ” she was quoted as saying, in response to a question at a news conference. “But I think that shows the wrong focus. I must make it clear that this is an issue of respect for the nation and whether you recognize that you are Chinese.”

Hong Kong’s soccer authorities have repeatedly appealed in vain for fans to desist, with Football Association official Pui Kwan-kay describing the catcalls as “stupid” and “meaningless.”

“I cannot rule out more jeers in the next game as, honestly, there are no measures we can take to stop fans booing,” Pui was reported as saying before the Malaysia game.

Although Hong Kong returned to China in 1997, it continues to compete separately in major sporting events such as the Olympics and the soccer World Cup.

Polls show a rising majority of residents of the territory see themselves as Hongkongers first and Chinese citizens afterward. A small but vocal minority have even begun to call for independence from China since the failure of the Umbrella Movement to wring concessions from the governments in Hong Kong and Beijing.

Opinion about the protests is split in Hong Kong, with some defending the fans’ rights to make their feelings heard and others castigating them as “uncivilized losers.”

China’s law, which went into effect Oct. 1, bans the use of its national anthem in commercial advertisements or at funerals, and stipulates that attendees at events where the anthem is played must stand up straight and remain solemn. It also says the anthem should be included in school textbooks.

Under Hong's Kong's existing laws, anyone who desecrates the national flag can be fined up to HK$50,000 ($6,400) and jailed for up to three years.

In the United States, however, the Supreme Court ruled in 1990 that it is unconstitutional for any level of government to prohibit the desecration of the flag, under the constitution's First Amendment protection of free speech.

Amber Ziye Wang contributed to this report.