U.K. lawmakers have taken another step toward wresting control of the Brexit process away from Prime Minister Boris Johnson and his government.

A majority of lawmakers, including opposition politicians and so-called “rebel” members of the ruling Conservative Party, voted 328 to 301 Tuesday to take control of parliamentary business from the government. This would in theory allow them to push through legislation that could block government efforts to withdraw the U.K. from the EU without a deal on October 31. Johnson said he would bring forward a motion for a new general election following the setback.

Government ministers had acknowledged ahead of the vote that it would test the parliament’s confidence in Johnson’s relatively new government; could serve to undermine his Brexit strategy, and might precipitate fresh elections.

Another vote will now be held as early as Wednesday on the legislation, and, if passed, it would pressure the prime minister to request another extension to the U.K.’s departure date, to January 31, 2020.

A draft copy of that legislation released by one of its authors Monday night indicated the prime minister would be obliged to request an extension by October 19 unless parliament approves a new Brexit deal or signs off on a no-deal departure.

The legislation has been tabled by lawmakers who say they are concerned over the economic and political consequences of an abrupt departure from the EU. This “disorderly” exit, as they have termed it, would see the U.K. leave the EU’s single market, customs union and other EU institutions and regulatory bodies overnight, without a transition period in which to negotiate a new trade deal.

Johnson has insisted that the U.K. needs to keep the threat of a no-deal departure intact in order to achieve concessions from the EU on the currently available Brexit deal. The U.K. leader, a pro-Brexit politician who was an integral part of the 2016 Vote Leave campaign, had once again promised in a national televised address on Monday night that the U.K. would leave the EU on October 31 “no ifs and no buts.”

The Conservative-led government had earlier warned its own MPs (Members of Parliament) that they risked expulsion from the party’s parliamentary grouping and the loss of Conservative support in any future election if they were to vote for this legislation to block a no-deal Brexit. After one member publicly defected to the opposition Liberal Democrats as Johnson began speaking Tuesday evening, almost two dozen other high profile members have been stripped of their formal party affiliation for their opposing votes.

And officials at 10 Downing Street have told British media outlets that October 14 or 15 would be a likely date for a new national vote, although the government would need two-thirds of parliament to bring that plan into effect.

Johnson indicated after his defeat late Tuesday night that he would now pursue an election through that parliamentary route, though opposition lawmakers made clear they would require Wednesday’s legislation be passed before they offer their consent.

Johnson became prime minister in July after his predecessor Theresa May failed three times to win parliamentary approval for her Brexit agreement with the EU, and then resigned. But after his election and a publicly trumpeted promise to restart Brexit talks, the European Commission Tuesday in Brussels said there had so far been no significant progress made on efforts to amend the terms of May’s deal, which was originally agreed back in November last year.

A particular stumbling block to British parliamentary approval over the past 10 months has been the “Irish backstop,” an insurance policy designed to maintain a frictionless border between the Republic of Ireland and Northern Ireland, that would take effect in case the EU and the U.K. fail to agree a trade deal during a 21-month post-Brexit transition period. The EU has insisted that the U.K. has not presented any viable, concrete alternatives to this backstop since Johnson took office.

Analysts have pointed out that if parliament votes in favor of legislation that might oblige Johnson to request a further delay to Brexit, the EU would still need to approve an extension. And allies of the prime minister indicated this past weekend that his government might also choose to ignore the legislation’s requirements under certain circumstances.

But if Johnson does pursue and win parliamentary approval for a snap election, to hold on to what he perceives as the option of a no-deal Brexit, current polls indicate a highly uncertain electoral outcome thanks to the fragmented nature of British politics and public opinion on Brexit.

Conservative MP Dominic Grieve, among the group of lawmakers proposing the bill to block a no-deal Brexit, told CNBC Tuesday morning that he was confident the vote would pass, though he called the current set of circumstances “a very difficult situation.”

“If the legislation goes through, my hope would be that it will force the prime minister and sections of my party to reset the discussion, and to start thinking sensibly about a way out of the hole which we have succeeded in digging for ourselves as a country,” he told CNBC’s Willem Marx.

“My own personal view is that the sensible course of action is to have another referendum which could be determinative. Failing that, either there has to be a deal that is acceptable to the House of Commons (the lower house of parliament) … or potentially we could have a general election, but my anxiety with that is that a general election is at great risk of delivering another hung parliament. If that happens, we’re back to square one.”

—CNBC’s Willem Marx and Uri Inspector contributed to this article.