MSPs have set themselves at odds with Westminster by backing a Scottish government motion that makes clear that Holyrood "does not consent to the EU Withdrawal Bill".
The move could trigger a constitutional crisis, as it would be the first time the UK government has pushed through laws against the will of Scotland, if Ms May decides to press ahead with the legislation.
It comes as the prime minister struggled to break the deadlock over customs arrangements after Brexit, which has divided her cabinet.
Scottish Labour, the Greens and the Liberal Democrats backed the SNP in the Holyrood vote, which gave Nicola Sturgeon's party the numbers to defeat the Scottish Conservatives on the motion.
Scottish government Brexit minister Mike Russell previously said the bill "rides roughshod over devolution", as it could see some powers returned to Whitehall, rather than Holyrood, after the UK leaves the EU.
Speaking after the vote, he said: “The UK Government wants to take a power to restrict the competence of this Parliament.
“And it wants to be able to exercise this power even in the face of an explicit decision by this Parliament that it should not.
“The Scottish Parliament has now said overwhelmingly that this attempt to undermine devolution is unacceptable.”
Such a move would not prevent the UK government from introducing the legislation - but it would be the first time Westminster has pushed through laws against the wishes of the Scottish Parliament.
Mr Russell will now write to David Lidington, Ms May’s de facto deputy, who has been leading the talks with the devolved administrations.
Earlier, David Mundell, the Scottish secretary, rejected claims of a "power grab" as he said no changes were being made to existing arrangements.
He said: "Obviously, it's up to the Scottish parliament to take whatever decision they want to take.
"I still hope that they will take a positive decision, that they will take a step back and look at the proposal that we have put forward in relation to the specific arrangement which is just to keep 24 areas which affect the whole of the UK exactly as they are at the moment, so that the day after we leave the EU nothing will have changed.
"Then there will be an opportunity to have a discussion across the whole of the UK as to what new arrangements should replace those which are already in place. I just don't see how that can be characterised as a power grab."
It comes after a meeting of Ms May's Brexit war cabinet, where senior figures are trying to find a way to end the standoff over the future customs relationship with the EU.
Ministers have been split into two groups to explore the two options - a "customs partnership", which is favoured by Ms May, and "maximum facilitation" plans backed by Brexiteers.
The EU is pressing for "substantive progress" from Britain on the future of the Irish border in time for a crunch European Council summit just six weeks away.
Register for free to continue reading
Registration is a free and easy way to support our truly independent journalism
By registering, you will also enjoy limited access to Premium articles, exclusive newsletters, commenting, and virtual events with our leading journalists
Already have an account? sign in
Join our new commenting forum
Join thought-provoking conversations, follow other Independent readers and see their replies