A self-described feminist with controversial views on transgender rights was met by hundreds of protesters as she gave a speech at a library in Canada.

Freelance writer Meghan Murphy was hosted by Toronto Public Library on Tuesday evening where she gave a speech about her views on gender identity.

Hundreds gathered outside to denounce the event and decry Murphy as 'anti-transgender'.

As she spoke, demonstrators aligned with Pride Toronto and others who felt Murphy was offensive to LGBT communities gathered outside with placards, chanting: 'Trans rights are human rights!'

Toronto officers were present inside and outside the event to 'keep the peace,' according to local media reports.

Murphy is known for making controversial remarks about transgender rights undermining women's rights and has argued that trans women should be banned from women's locker rooms, bathrooms and prisons.

Freelance writer Meghan Murphy (pictured) was hosted by Toronto Public Library on Tuesday evening where she gave a speech about her views on gender identity

Murphy is known for making controversial remarks about transgender rights undermining women's rights and has argued that trans women should be banned from women's locker rooms, bathrooms and prisons

LGBT rights activists gather outside Toronto Public Library waving placards and chanting: 'Trans rights are human rights'

Murphy spoke for around 30 minutes, during which time she reiterated her stance on transgender issues, saying: 'If you're born male, you remain male for life.'

She added that the 'trans-activist movement has made for the erasure of women.'

Murphy has previously said that she believes the transgender movement is 'regressive and sexist'.

'Under current trans activist doctrine we're not allowed to exclude a man from a woman's space if he says that he's female and I find that quite dangerous and troubling,' she told the BBC.

Murphy spoke for around 30 minutes, during which time she reiterated her stance on transgender issues, saying: 'If you're born male, you remain male for life'. She added that the 'trans-activist movement has made for the erasure of women'

Protestors heckling attendees who are leaving the #MeghanMurphy speaking session at the Palmerston library. pic.twitter.com/612pPMbkhh — Kamil Karamali (@KamilKaramali) October 29, 2019

Pride Toronto later tweeted: 'What amazing turn out tonight to declare no to hate. #prideto.'

Global News reporter Kamil Karamali said Murphy had planned to speak to reporters after the event but ended up leaving through the back exit 'almost immediately' after her session was done.

Other attendees were escorted from the back of the venue and were met with boos from the protesters.

'Protestors heckling attendees who are leaving the #MeghanMurphy speaking session at the Palmerston library,' Karameli tweeted alongside a video of protesters separated by event attendees by a wall of police.

The event was organized by Radical Feminists Unite and tickets were sold out. The feminist group previously released a statement on why they invited Murphy to speak, saying 'she is respected as an important feminist voice, not only in Canada, but around the world.

'She has built one of the largest and most read feminist websites in the English speaking world, and has exemplified bravery and steadfastness in her refusal to back down on behalf of women.'

As she spoke, demonstrators aligned with Pride Toronto and others who felt Murphy was offensive to LGBT communities gathered outside the library

The statement added: 'We are not a hate group, and we do not espouse hate speech, or advocate for the removal of rights from any marginalized group.'

The library came under intense scrutiny for giving the event the green light.

City librarian Vickery Bowles released a statement earlier this month defending the library's decision and saying that it has 'an obligation to protect free speech'.

Bowles added that the library supports the LGBT community and would cancel any event that it believes would be promoting 'discrimination, contempt or hatred for any individual or group.'

The decision to hold the event faced intense backlash. Toronto Mayor John Tory even weighed in on the debate, saying he was 'disappointed' that the event had gone ahead.

An online petition calling for the cancellation of the talk had accrued more than 8,000 signatures by Tuesday.

Pride Toronto said in a statement that Murphy's views are 'a denial of the lives, experiences and identities of trans people.'