The Coalition Avenir Quebec said Monday night’s by-election is sending a strong message to the Liberal Party.

Newcomer Genevieve Guilbault captured 51.04 per cent of the vote in the Quebec City riding of Louis-Hebert.

"We are positively surprised by those results," said Guilbault.

The riding traded hands between the Liberal Party and the Parti Quebecois from its creation in 1966 until Sam Hamad was elected in 2003; it has been Liberal ever since.

On Monday night, both CAQ leader Francois Legault and PQ leader Jean-Francois Lisée called it a "Liberal fortress," and though the CAQ felt a win was within their grasp, party members said they were surprised by the magnitude of the win.

Legault said it send a scathing message to the Liberal government that there can be changes in 2018.

“Tonight showed us that we can beat the Liberals just about anywhere in Quebec. We had a very large majority,” he said.

"At 19 percent the Liberal party is very low. They are at a record low."

Lisée agreed with that statement, saying voters are choosing anyone but Couillard.

"Yesterday in Louis-Hebert they decided to coalesce around the CAQ to make sure that the Liberals were not elected. In Marie-Victorin and in St-Jerome just a couple of months ago they coalesced around the Parti Quebecois," said Lisée.

Hamad was removed from Premier Couillard's cabinet in 2016 following allegations he had helped a company trying to win a government grant, and stepped down as an MNA earlier this year.

Ihssane El Ghernati, a former political attaché for Liberal cabinet minister Sam Hamad before he resigned from politics, was second with about 18.71 per cent of the vote -- an almost 30 per cent drop from the last election for the party. The PQ finished third with 16.26 per cent.

The Liberal Party struggled to find someone willing to replace Hamad as a candidate, finally settling on Eric Tetrault. However on Sept. 6, Tetrault withdrew his candidacy following allegations that he had harassed co-workers.

Most MNAs in the Liberal caucus chose not to comment on their loss, but those who did said the consultations on systemic racism may be to blame.

The CAQ candidate also withdrew at the same time following similar allegations, clearing the way for Guilbault's candidacy.

The 34-year-old newcomer is a former Liberal political attaché.

She lives in the riding and had been planning to run in the Quebec City area next year, during the 2018 general election, following the birth of her child. She is due to give birth in three months.

Guilbeault said her election despite the pregnancy sends a positive message that young women who have families can get into politics.

“Of course I thank my companion for being available to go in this journey with me and to take care of the child – the soon to be born child – and that’s a family project. I think it reflects the reality in 2017,” she said.