Conservative lawmakers in Britain have begun casting secret ballots in a vote of non-confidence that would see Prime Minister Theresa May removed as party and government leader if she loses, while throwing U.K. politics deeper into crisis and Brexit further into doubt.

Voting will go on for two hours in London — until 3 p.m. ET — with results expected by 4 p.m. ET.

May has vowed to fight for the leadership of her party and the country "with everything I've got" after opponents, who have been circling for weeks, finally got the numbers they needed to spark a secret-ballot vote among Conservative Party lawmakers.

In a meeting with Conservative MPs just ahead of the vote, lawmakers in the room say she told them she will not lead the party into the next election, but that she made it clear now is not the time for a change in leadership.

The threat to May has been building as pro-Brexit lawmakers within the Conservative Party grew increasingly frustrated with May's conduct of Brexit and the divorce deal she has agreed with the European Union.

The challenge throws Britain's already rocky path out of the EU, which it is due to leave in March, into further chaos. It comes days after May postponed a vote to approve the divorce deal to avoid all-but-certain defeat in the House.

Many supporters of Brexit say May's deal, a compromise that retains close economic ties with the EU, fails to deliver on the clean break with the bloc that they want.

UK waking up to the news Theresa May will face a no-confidence vote within her own governing Conservative party tonight after her opponents garnered 48 signatures to trigger it. She need a simple majority of 158 votes to win. If she squeaks by she can't be challenged for a year. —@mevansCBC

Former environment secretary Owen Paterson accused May of acting like a "supplicant" in dealings with the EU.

"She's not the person to see Brexit through," he said.

Leading pro-Brexit legislators Jacob Rees-Mogg and Steve Baker said in a joint statement that "in the national interest, she must go."

But in a defiant statement outside 10 Downing Street, May said "a change of leadership in the Conservative Party now will put our country's future at risk."

She said ousting her and holding a leadership vote — a process that could take weeks — could result in Brexit being delayed or even stopped.

January deadline

May, who spent Tuesday touring EU capitals to appeal for changes to sweeten the divorce deal for reluctant U.K. lawmakers, has until Jan. 21 to hold a vote on her deal in Parliament, a timetable that could be scuttled if she is ousted.

Opposition lawmakers expressed astonishment and outrage at the Conservative civil war erupting in the middle of the fraught Brexit process.

"This government is a farce, the Tory party is in chaos, the prime minister is a disgrace," Scottish National Party Leader Ian Blackford said during a pugnacious prime minister's questions session in the House of Commons.

Prime Minister Theresa May, centre, responds to lawmakers' questions inside the House of Commons in London on Wednesday. She has vowed to fight for the leadership of her party and the country 'with everything I've got.' (Mark Duffy/UK Parliament via Associated Press)

On Wednesday morning, Graham Brady, who heads a committee overseeing Conservative leadership contests, said he had received letters from at least 48 lawmakers asking for a vote. That's the 15 per cent of Conservative legislators, the number needed to spark a vote under party rules.

If she loses the confidence vote, May must step down and there will be a contest to choose a new leader. She will remain leader and prime minister until the successor is picked. But if she wins, she can't be challenged again for a year.

Brady said that the party aimed to finish the first stage of any leadership contest — in which lawmakers vote to whittle down the field of contenders to two — before Parliament breaks for Christmas on Dec. 20. The final two contenders would then be put to the nationwide party membership in a postal ballot.

May cancelled a trip to Dublin to meet Irish Prime Minister Leo Varadkar, to stay in London and battle for lawmakers' support.

158-vote threshold

May, a 62-year-old vicar's daughter who voted to remain in the EU, won the top job in the turmoil that followed the 2016 EU referendum but promised to implement Brexit, while keeping close ties to the bloc, as a way to heal a divided country.

If all Tory lawmakers cast ballots, May needs 158 votes to win, though a narrow victory could leave her weakened and under pressure to resign. But allies said May would stay in post even if she secured a wafer-thin win.

"I think she needs to win by one," said International Trade Secretary Liam Fox.

Pro-Brexit and anti-Brexit demonstrators shout at each other opposite the Houses of Parliament on Tuesday. (Henry Nicholls/Reuters)

Ahead of the vote, at least 185 of 315 Conservative lawmakers expressed public support for her.

However, some lawmakers who have backed May publicly have said in private that they will vote against her, according to British political commentators.

Several leading Brexiteers, including former foreign secretary Boris Johnson and ex-Brexit secretary Dominic Raab, have said loudly that they think they could get a better deal with the EU, and they are likely to enter a race to replace her.

For what it’s worth, bookmakers are giving Boris Johnson the best odds (5/1) to become the next Tory leader if May is ousted. He’s followed by Dominic Raab and Sajid Javid (both 6/1). —@thomasdaigle

More conciliatory candidates, including Home Secretary Sajid Javid and Work and Pensions Secretary Amber Rudd, are also possible contenders.

Ahead of the vote, cabinet colleagues rallied to May's support.

Javid tweeted that a leadership contest, with Brexit little more than three months away, "will be seen as self-indulgent and wrong. PM has my full support and is best person to ensure we leave EU on 29 March."

'We need no distractions'

Justice Secretary David Gauke said: "I think it's vital for the country that she wins tonight."

If May loses, "I don't think we will be leaving the European Union on the 29th of March," he said.

Former prime minister David Cameron, who called the Brexit referendum and resigned after voters elected to leave the EU, also weighed in ahead of the vote.

From the man who started all this ... <a href="https://twitter.com/hashtag/cbc?src=hash&ref_src=twsrc%5Etfw">#cbc</a> <a href="https://t.co/m9onrUkJLS">pic.twitter.com/m9onrUkJLS</a> —@NahlahAyed

European Union leaders tried to stay out of the fray. There was no change to plans for May to address EU leaders about Brexit at a summit on Brussels on Thursday.

But the European Parliament's Brexit point man, Guy Verhofstadt, could not contain a note of annoyance.

Once again, the fate of EU–UK relations, the prosperity of businesses & citizens' rights are consumed by an internal Conservative party catfight over Europe. I hope that, whatever happens, at least the vote will make clear that a disastrous no–deal is off the table. <a href="https://twitter.com/hashtag/Brexit?src=hash&ref_src=twsrc%5Etfw">#Brexit</a> —@guyverhofstadt

"Once again, the fate of EU-U.K. relations, the prosperity of businesses & citizens' rights are consumed by an internal Conservative party catfight over Europe."

Brexit is Britain's most significant political and economic decision since the Second World War, though pro-Europeans fear the departure will weaken the West as it grapples with the presidency of Donald Trump and growing assertiveness from Russia and China.

The outcome will shape Britain's $2.8 trillion economy, have far reaching consequences for the unity of the United Kingdom, and determine whether London can keep its place as one of the top two global financial centres.