When China took control of Hong Kong from Britain in 1997, it signed an agreement guaranteeing the city a high degree of political autonomy for 50 years under the “one country, two systems” doctrine. On Monday, Beijing took a step away from that commitment, putting at risk the political stability and rule-based governance that have made Hong Kong a free-market mecca.

China intervened to effectively block two politicians, Sixtus Leung, 30, and Yau Wai-ching, 25, who were elected in September to the Hong Kong Legislature, from taking their seats. Their crime? Last month, at a swearing-in ceremony, they displayed a “Hong Kong is not China” banner; Mr. Leung used a derogatory term for China in his oath, and Ms. Yau used an obscenity. They support independence for Hong Kong. Beijing’s leaders consider such support a national security threat that must be crushed.

Hong Kong is governed under the Basic Law, a charter negotiated by China and Britain before the 1997 handover. It ensured Hong Kong its freedoms, including an independent judiciary. It also gives China’s Parliament the right to interpret the law, but until Monday, Beijing had not issued its own interpretation of any clause in the Basic Law without being asked for an interpretation by the Hong Kong government or judiciary. In this case, it intervened to say that office holders must “sincerely and solemnly” take loyalty oaths.

Beijing’s unilateral move was a heavy-handed attempt to silence democratic voices. And it raised new questions about China’s willingness to reinterpret agreements for its own benefit.