Media playback is unsupported on your device Media caption The result is announced as MPs vote by 286 to 344 to reject the government’s withdrawal agreement

All 13 Scottish Conservative MPs have backed Theresa May's EU withdrawal deal in a Commons vote - but could not prevent it being defeated.

The PM's proposals had previously been opposed by Aberdeen South MP Ross Thomson and his Moray colleague Douglas Ross.

Mr Thomson and Mr Ross confirmed ahead of the vote that they would now be backing it.

But MPs ultimately rejected the withdrawal deal by 344 votes to 286.

The deal was opposed by the SNP, Liberal Democrats MPs and most Labour MPs, as well as 34 Conservative MPs and the DUP, which props up Mrs May's minority government.

The result of the vote, which was held on the day the UK was originally due to leave the EU, means the country has missed an EU deadline to secure an extension of the Brexit process and leave with a deal on 22 May.

The prime minister said the UK would now have to find "an alternative way forward", which was "almost certain" to involve holding European elections.

Mrs May now has until 12 April to seek a longer extension to the negotiation process to avoid a no-deal Brexit on that date.

Media playback is unsupported on your device Media caption Nicola Sturgeon: 'Put Brexit back to the people'

Ahead of the vote, Mr Thomson - a hardline Brexiteer and close ally of Boris Johnson - posted on Twitter: "After a lot of thought, wrestling with my conscience and talking to good friends and colleagues, I have reluctantly decided to vote for the deal today.

He added: "We will have a new leader and prime minister who will have the confidence, nerve and political will to ensure that if we ever did find ourselves in the backstop then there is no way that they will allow the EU to keep a sovereign UK in the backstop against its will.

"Politics is the 'art of the possible'. Sometimes decisions aren't about what is right or what is best but about what you can actually get done.

"That is why I have reluctantly concluded that, with a heavy heart, I have to vote for the Withdrawal Agreement today".

Image copyright Jeff J Mitchell Image caption Scottish Conservative MPs have been split over Brexit and the prime minister's withdrawal deal

In a post on his website, Mr Ross said he would be joining Mr Thomson in voting for the prime minister's deal because "parliament is in a mess and the public want us to sort this out".

John Lamont, the Conservative MP for Berwickshire, Roxburgh and Selkirk, voted against the prime minister's deal in the first "meaningful vote" - but changed his mind by the time the second one was held and again voted in favour on Friday afternoon.

MPs were asked to approve only part of the PM's Brexit deal - the withdrawal agreement, which covers the terms of exit - and not the political declaration on post Brexit EU-UK relations.

The withdrawal agreement includes:

Details of the UK's £39bn financial settlement with the EU

Guarantees about the rights of EU and UK citizens

Details of the "transition period" until the end of 2020

Controversial arrangements for the backstop, which seeks to prevent the return of customs infrastructure at the Irish border in the event no UK-EU trade deal is enforced.

The prime minister said that the outcome was "a matter of profound regret", adding that "I fear we are reaching the limits of this process in this House".

Media playback is unsupported on your device Media caption Theresa May: The rejection of the EU withdrawal agreement will have "grave" implications

Scotland's first minister, Nicola Sturgeon, called on the prime minister to "accept that this deal is dead" and not to attempt to bring it back for a further vote.

Ms Sturgeon added: "It is now for the House of Commons, starting again on Monday, to try to find the best way forward. I hope that is to put the issue back to the people in another referendum, or indeed to revoke Article 50.

"That is the only way to avoid a no-deal Brexit, because what must not be countenanced is falling out of the European Union with no deal."

Scottish Chambers of Commerce head Liz Cameron said the rejection of the prime minister's deal had left the country's businesses "in despair" as it "muddies the waters of our future even more".

Ms Cameron added: "What we need from our parliamentarians is a laser focus on the business and economic challenges the country faces, which has so far been completely absent in the midst of these political tactics."

Labour leader Jeremy Corbyn said the prime minister's approach to Brexit has been "nothing short of a shambles" and was based on the interests of the Conservative Party, not the country.

Mr Corbyn repeated his call for a general election to be held in a bid to end the deadlock over Brexit.

Please upgrade your browser to view this interactive How did your MP vote on the withdrawal agreement? Enter a postcode, or the name or constituency of your MP Seat vacant

What happens next?

Monday, 1 April: MPs hold another set of votes on various Brexit options to see if they can agree on a way forward

Wednesday, 3 April: Potentially another round of so-called "indicative votes"

Wednesday, 10 April: Emergency summit of EU leaders to consider any UK request for further extension

Friday, 12 April: Brexit day, if UK does not seek/EU does not grant further delay

23-26 May: European Parliamentary elections