The New Democrats won a crucial provincial byelection in British Columbia on Wednesday that allows Premier John Horgan's minority government to maintain its grip on power after facing a spirited campaign from the Opposition Liberals.

With the win, the NDP has 41 seats in the legislature and continues to hold power with the support of three Green party members in the house. The Liberals have 42 seats and there is one Independent, who serves as legislature Speaker.

"It's great to have so many people interested in the events in Nanaimo," said Horgan, acknowledging that the byelection became a provincial and local test for his government.

"This was an exciting, pivotal election campaign," he said. "This means we can continue to deliver on the issues we campaigned on. Health care, education, housing, those are the things people are talking about."

With almost all the votes counted, New Democrat Sheila Malcolmson had an almost 1,900 vote lead over B.C. Liberal Tony Harris.

Malcolmson had about 49 per cent of the votes cast in the six-candidate field, while Harris took just over 40 per cent, about an eight percentage point improvement over the votes the party took in the 2017 general election.

A Liberal win would have tipped the balance of power in the legislature and put Horgan's government on shaky ground.

Horgan said the byelection result shows voters support his government's policies.

"The project continues," said Horgan, adding that what Malcolmson heard during the campaign "was validation of what we've been doing for the past 18 months."

Malcolmson said she will work with the party to build affordable housing, expand childcare and improve the environment and health care.

"Holy smokes, what a beautiful crowd," she said after being introduced by Horgan. "We've got a lot of work to do starting tomorrow."

Nanaimo traditionally votes NDP, but Harris has deep family roots in the Vancouver Island city and campaigned to bring economic development and infrastructure to the often neglected community.

Malcolmson resigned her seat in the House of Commons to run in the byelection, saying she wanted to ensure the policies of the former B.C. Liberal government did not return because they increased homelessness and the cost of housing in the city.

Malcolmson said she felt the pressure of the campaign as the Liberals pushed for a breakthrough.

"Of course, I was worried," she said. "I would be a terrible candidate if I wasn't."

Nanaimo resident Ken Pearce said Malcolmson is well-known in the city.

"She works hard. A lot of people didn't want a change in government," Pearce said at Malcolmson's headquarters.

Green candidate Michele Ney, the daughter of longtime Nanaimo mayor Frank Ney, campaigned on making the city a clean economy powerhouse.

Ney drew just over seven per cent of the vote, well below the almost 20 per cent the party received in the last provincial election.

Green Leader Andrew Weaver said the party support in the riding is stronger than the byelection results showed, but voters didn't want to see the NDP toppled from power.

"While disappointing, tonight's results were not unexpected, given the conversations we have had with Green voters over the past few weeks," he said in a statement.

"I can say with absolute certainty that our support exceeds the votes cast for the party today. I spent a lot of time in Nanaimo campaigning with Michele, and many members, donors and supporters of our party came up to us saying that while they continued to support our party, they felt they needed to vote for the NDP in this byelection so that the government and our agreement with them can continue."

The byelection was called when New Democrat Leonard Krog resigned last year after he was elected the city's mayor.

Keep reading

What a relief. Now Horgan won't have to bring the pharmacare legislation to the floor just so the people of BC can watch the BC LibSoCred Party vote it down. He won't have to call for a full inquiry into the spending scandal and the money laundering scandals that happened under the watch of the Campbell and Clark governments - again just so the people of BC can watch the LibSoCreds can vote that down too. Both can proceed on their won merits and not as political ploys intended to humiliate the opposition.

Congratulations to Sheila and John. I want to live in a world that doesn't punish people for being poor. Carry on with your fight against the pressure to eliminate human need concerns in favour of an absolute focus on money and power. The latter has a big bank account, the oil industry, and media. The fight must be arduous and endless.