The Hong Kong government has withdrawn the extradition bill that sparked months of chaotic protests on the same day the murder suspect who was the catalyst for the plan is released from jail.

Months of increasingly violent pro-democracy demonstrations in the financial hub were sparked by protests against the now-cancelled extradition law - which would have allowed suspects to be extradited to mainland China.

The catalyst for the law was Hong Konger Chan Tong-kai, 20, who is wanted in Taiwan for the 2018 murder of his pregnant girlfriend Poon Hiu-wing.

Chan, who spent 18 months in custody over money laundering charges, apologised to the victim's family and the city as he left the maximum security prison.

Hong Konger Chan Tong-kai is wanted in Taiwan for the 2018 murder of his pregnant girlfriend Poon Hiu-wing

He apologised for the great 'pain and agony' he had caused Poon's family, and hoped his decision to surrender would offer them some relief.

'As for the society and Hong Kongers, I could only (say) I'm sorry,' he said, adding that he hoped to be forgiven and start life afresh.

Chan, ignoring reporters' other questions, said: 'I am willing to surrender myself... and go back to Taiwan to face the trial and serve the sentence.'

Taiwan announced Tuesday it was willing to send a delegation to bring Chan back to the self-ruled island for trial, but Hong Kong rejected the offer, saying the suspect should be allowed to fly unaccompanied to Taiwan to turn himself in.

It comes after reports in the Financial Times that China plans on replacing Hong Kong chief executive Carrie Lam, something denied in Beijing as a political rumour.

The controversy is rooted in the unwillingness of Hong Kong, a semi-autonomous Chinese region, to recognize the legitimacy of the legal bodies in Taiwan, which the communist authorities in Beijing consider a breakaway province.

China has refused all contact with the administration of Taiwan's directly elected President Tsai Ing-wen over her refusal to endorse Beijing's contention that the island is Chinese territory awaiting annexation.

That appears to have compelled Hong Kong to reject cooperation with Taiwan over Taipei's insistence on a 'mutual legal assistance' deal with Hong Kong that would require their institutions to deal with each other on an equal basis.

Hong Kong Chief Executive Carrie Lam, center, arrives at chamber of the Legislative Council in Hong Kong

Tsai herself weighed in Wednesday on the Chan case, emphasizing that, although both the alleged perpetrator and the victim are from Hong Kong, Taiwan was willing to put Chan on trial if Hong Kong does not.

However, she said there was no possibility of Chan simply catching a flight to Taipei and insisted Taiwan would not sacrifice its sovereignty in handling the matter.

'I would like to explain that in this case, the murderer is a wanted subject in Taiwan. He is already a wanted criminal suspect in Taiwan with a warrant out for his arrest,' Tsai said during a visit to the Taiwanese-held island of Kinmen just off the Chinese coast.

'Therefore, regarding this case, there is no issue of free travel or just being a backpacker. There is only the matter of arrest and no question of simply turning oneself in,' Tsai said.

Chan Tong-kai, center, talks to the media as he is released from prison in Hong Kong Wednesday

Taiwan's Mainland Affairs Council said allowing a murder suspect to fly on his own would ignore the safety of other passengers and that Hong Kong's approach would indulge Chan and make Hong Kong 'a criminal paradise where murderers can walk around.'

Hong Kong leader Carrie Lam had repeatedly cited Chan's case as justifying the proposed amendments to the extradition legislation, saying he could not be sent to the self-ruled island because there was no extradition agreement in place.

But the proposal stoked widespread fears residents of Hong Kong, which has maintained its own independent courts since reverting from British to Chinese rule in 1997, would be put at risk of being sent into mainland China's Communist Party-controlled judicial system.

Chan Tong-kai, left, bows after talking to the media as he is released from prison in Hong Kong Wednesday

Lam was forced to announce last month that she would drop the bill in the face of fierce opposition.

The protests erupted in early June and snowballed into the city's biggest political crisis in decades, expanding to demands for universal suffrage and an investigation into allegations of police abuses, most recently including the spraying of a mosque and bystanders with high-pressure blue-dyed water from an urban assault vehicle.

Amid the ongoing political chaos and street violence, Lam's future as Beijing's pick to lead Hong Kong has been repeatedly questioned.

The newspaper Financial Times reported Beijing may be planning to replace Lam with an interim chief executive as early as March, but is holding off so as not to appear to be caving into the opposition's demands.