All three devolved parliaments have rejected the UK Government's key Brexit legislation.

In an unprecedented move, Scotland, Northern Ireland and Wales refused to consent to the EU Withdrawal Bill - the first time all three have rejected legislation affecting devolved matters.

Wales was the last nation to take the decision, with 35 assembly members, from Labour and Plaid Cymru, opposing the law, while 15 backed it.

Read moreHolyrood rejects Brexit deal as constitutional crisis looms

First Minister for Scotland, Nicola Sturgeon, described the situation as "unprecedented and momentous".

She added: "For the UK to ignore that reality will simply demonstrate how broken the Westminster system is."

Brexit Secretary Stephen Barclay had appealed to Welsh ministers not to vote the bill down, saying it respected the result of the 2016 referendum when Wales voted to leave.

However, First Minister for Wales, Mark Drakeford, said the law unilaterally rewrites the way devolution works in in his country.

The legislation is currently passing through the UK Parliament - the government lost three votes in the House of Lords on the legislation on Tuesday.

Read moreStormont Assembly to join Holyrood in 'rejecting Brexit deal' as constitutional crisis looms

Normally the devolved assemblies and parliaments must give their permission before Westminster can legislate on issues that impact them.

Consent has not been given by any of the three bodies, although the moves are not legally binding and will not stop the UK government pressing ahead.

The decision in Wales came as peers in the House of Lords urged the government to ensure the devolved administrations have an input into negotiations on the UK's future relationship with the EU.

Ministers were told that guaranteeing their involvement and seeking consensus would strengthen the Union.

The call came as the House of Lords continued its scrutiny of Boris Johnson's Brexit deal on which peers have already inflicted three defeats.

Speaking at report stage of the European Union (Withdrawal Agreement) Bill, which enables the UK to leave the EU on January 31, former Lord Chief Justice of England and Wales Lord Thomas of Cwmgiedd warned that measures were needed "otherwise the Union will be imperilled".

Read moreExecutives in key Scottish sectors voice Brexit fear

Lord Thomas called for the forum, known as the Joint Ministerial Committee (EU Negotiations) which is made up of ministers from the UK and devolved administrations, to be put on a legal footing.

The independent crossbencher said: "The proper approach is to involve the devolved governments fully in the negotiations by consulting them and trying to reach a consensus."

He added: "It is simply a way of trying to persuade and ensure that the Government acts in such a way that it strengthens the Union.

"And it takes into account and is seen to take into account the interests of Wales, Scotland and Northern Ireland."