Theresa May’s government has suffered a major defeat over Brexit in the House of Lords with peers backing an amendment to the EU Withdrawal Bill calling on ministers to explain what they have done to ensure that Britain can remain in a customs union after it leaves the European Union. 348 peers backed the amendment, which was proposed by former diplomat John Kerr, with 225 voting against.

It does not require the government to remain in a customs union but demands that the government should have to explain to parliament what it has done to negotiate “an arrangement which enables the United Kingdom to continue participating in a customs union” with the EU.

Shadow Brexit secretary Keir Starmer welcomed the vote, which he described as an important step forward.

“Labour has long championed the benefits of a customs union as the only viable way to protect jobs, support manufacturing and help avoid a hard border in Northern Ireland after we leave the EU. That is why we have called on the Government to negotiate a new comprehensive UK-EU customs union after Brexit as part of a close future relationship with the EU. Theresa May must now listen to the growing chorus of voices who are urging her to drop her redline on a customs union and rethink her approach,” he said. Related Northern Ireland fishermen ‘looking forward to new markets’ after Brexit

Tusk again warns no Brexit deal for UK without Border solution

Brexit drags European car sales to weakest first quarter in five years

The Department for Exiting the European Union expressed disappointment at the vote and restated the government’s commitment to leave the customs union and the single market when Britain leaves the EU.

“The fundamental purpose of this Bill is to prepare our statute book for exit day, it is not about the terms of our exit. This amendment does not commit the UK to remaining in a customs union with the EU, it requires us to make a statement in parliament explaining the steps we’ve taken. Our policy on this subject is very clear. We are leaving the customs union and will establish a new and ambitious customs arrangement with the EU while forging new trade relationships with our partners around the world,” it said.

The debate in the Lords found former Conservative cabinet heavyweights on opposing sides, with former chancellors Nigel Lawson and Norman Lamont warning that the amendment would undermine the government during the Brexit negotiations. Former Conservative chairman and European commissioner Chris Patten mocked foreign secretary Boris Johnson’s vision of a “Global Britain” after Brexit.

“I don’t think that blithering on about Global Britain or pretending we haven’t been Global Britain for years, or repeating the Road to Mandalay whenever one is travelling, is going to make a difference to our trading opportunities. I don’t think we will do better than we are doing within the customs union,given that we start from a position in which we export to the European Union three and a half times as much as we do to the United States, five times as much as we do to the Commonwealth and six times as much as we do to all the BRICs combined,” he said.

The scale of the defeat in the House of Lords is a blow to the prime minister as she struggles to deal with a scandal over threats of deportation issued to members of the so-called “Windrush generation”, who arrived in Britain from the Caribbean as children during the 1950s and 1960s.