- Under the new legislation, many of Hong Kong's protests that took place last year would be punishable by law.
- It gives Beijing greater control on the city and has already had an impact on the protest movement, with prominent activist Joshua Wong resigning and withdrawing from his pro-democracy party.
Hong Kong police announced Wednesday their first arrests since China's national security law came into force.
The contentious legislation took effect hours after the Chinese parliament's top decision-making body voted to pass the National Security Law on Tuesday.
The law stipulates that a person who acts with a view to "undermining national unification" of Hong Kong with the mainland faces punishment of up to lifetime in prison, depending on the severity of the offense.
Under the new regulation, many of Hong Kong's protests that took place last year would be punishable by law.
Still, protesters took to the streets on Wednesday, which marked the 23rd anniversary of the city's handover from the U.K. to China. Hong Kong is a British colony that returned to Chinese rule on July 1, 1997.
Demonstrators were chanting slogans such as "Fight for freedom, stand with Hong Kong." Officers were seen stopping pedestrians and conducting searches, and some were taken away by police. Water cannons were also used.
Police later said on Twitter that more than 70 people had been arrested for participating in "unauthorized assemblies," including two suspected of violating the national security law.
Critics have long said the legislation will undermine Hong Kong's autonomy, promised to the Chinese territory when it was handed over to Beijing.
Hong Kong is governed under the "one country, two systems" framework. Under that structure, it enjoys certain autonomy that other Chinese cities do not have — including freedom of speech, the right to protest and limited election rights.
The new legislation gives Beijing greater control on the city and has already had an impact on the protest movement. Hours after the law was passed, Hong Kong activist Joshua Wong said that he was resigning as secretary general of pro-democracy group, Demosisto, and leaving the party. Other members, including Nathan Law and Agnes Chow, issued similar statements on social media and the party announced it would disband.
However, officials have refuted the idea that the law targets such activity.
"The purpose is not to take the pro-democratic camp in Hong Kong as an imaginary enemy. The purpose is combating a narrow category of crimes against national security," said Zhang Xiaoming, executive deputy director of Hong Kong and Macao Affairs Office of the State Council Wednesday.
"The 'one country two systems' has already spoken volumes of the political tolerance of the central (government)," he said, according to an official English translation of his Mandarin-language remarks.
"People with different views, they may continue to exist for a long time in Hong Kong ... You should not use this (difference in views) as a pretext to ... turn Hong Kong into a safe haven of anti-China forces," he added.
International leaders have condemned China's decision to pass the law, but Beijing maintains that foreign powers should not interfere in its domestic matters.
"As Beijing now treats Hong Kong as 'one country, one system,' so must the United States," White House National Security Council spokesman John Ullyot said in a statement, according to a Reuters report. "We urge Beijing to immediately reverse course."
— CNBC's Evelyn Cheng contributed to this report.