Gibraltar will retaliate if Spain imposes full border checks, the territory's chief minister has warned.
Fabian Picardo flashed the thinly-veiled warning after the Tories shelved negotiations with Brussels over a new post-Brexit deal for border checks and transit on the Rock until after the July 4 general election.
He said that 'sorrow might turn to anger quite quickly' if the talks were to break down.
Britain has been locked in talks over the status of the overseas territory - which has a land border with Spain - since Britain left the EU.
In April it appeared a deal had edged closer to being agreed with Mr Picardo telling reporters it was 'within kissing distance' of being rubber-stamped.
Gibraltar's chief minister Fabian Picardo (pictured speaking to the media in April) has warned the Rock could retaliate if Spain imposes full border checks
Britain has been locked in talks over the status of the overseas territory - which has a land border with Spain - since Britain left the EU. It will include moving the border to Gibraltar's airport
But despite at least 17 rounds of talks since October 2021, discussions have soured over Spain's insistence that the UK cede jurisdiction over Gibraltar's airport, which is on an RAF base, for an agreement to be reached.
There are also tensions over the role of Spanish police operating at the airport, which proved to be the main sticking point in the latest round of negotiations when foreign secretary Lord Cameron met with his Spanish counterpart José Manuel Albares, and Maros Sefcovic, of the European Commission.
Mr Picardo told the Gibraltar Chronicle yesterday: 'People in Gibraltar need to understand that the alternative to a treaty is potentially the full application of the Schengen border code with all of the massive difficulties that that would entail, and for us to do it reciprocally.
'In other words, if the Schengen border code is applied to Gibraltar and to crossings from Gibraltar to Spain, the government of Gibraltar will apply the same rules to crossings from Spain to Gibraltar. We will do that more in sorrow than in anger.'
He added: 'The reality is that we may fail to do a treaty, and we may also fail to agree a local border traffic arrangement.'
In theory, Gibraltar - home to more than 32,000 people - is currently outside the EU's customs union and not under free movement rules
The introduction at the airport of guards from EU border agency Frontex was thought to have solved the problem of policing the new Schengen border.
Yet tensions still remain due to the complexities over Madrid claiming sovereignty over Gibraltar.
'Spain needs to be understanding of why the Gibraltarian rejects Spanish presence in Gibraltar. It's a product of 60 years of what I might call almost abuse,' Mr Picardo said.
'We've seen the Spanish law enforcement agencies in Gibraltar as the instrument of the Spanish attempt not to recognise our waters and our territory.'
In theory, Gibraltar - home to more than 32,000 people - is currently outside the EU's customs union and not under free movement rules.
Parts of the new deal have already been agreed in principle, reported The Telegraph, which would include allowing Spanish and other EU planes to land at the airport for the first time in more than a decade.
However, Madrid has granted a temporary exemption for workers and tourists to avoid disruption on the narrow peninsula that jets off Spain's southern coast - leaving the overseas territory in a state of limbo since Brexit.
MPs raised 'serious concerns' last month that British negotiators have failed to stand up to Eurocrats during talks as it looked set to cave into Brussels over the deal.
Foreign Secretary Lord Cameron is leading talks with the EU in a bid to secure a deal and end the post-Brexit impasse
Madrid continues to claim sovereignty over the spit of land, which is located on the southern end of the Iberian peninsula. Pictured: Spanish Foreign Minister Jose Manuel Albares
In a letter to Foreign Office minister David Rutley, committee chairman Sir Bill Cash wrote: 'If agreed as you outlined to us, allowing current Schengen checks to be administered by [EU] Frontex border guards at the airport would erode UK sovereignty to the point of meaninglessness.
'From your evidence, we suspect that the UK Government is prepared to concede an arrangement that will leave Gibraltar's frontier British in all but name.
'The practical implications of this are seismic. You were unable to reassure us that UK nationals and Gibraltarians, wishing only to enter Gibraltar, would not have to undergo Schengen checks.
'You were also unable to rule out the possibility of UK and Gibraltarian nationals being refused entry to Gibraltar - a UK Overseas Territory - by Schengen (EU) border guards.'
The temporary agreement could be rescinded by Spain at any time, and so the negotiations are working towards agreeing common travel between Gibraltar and the EU's Schengen zone, which would remove most border controls.
Gibraltar has been ruled by Britain since 1713, but is self-governing in all areas except for defence and foreign policy.
Britain and Spain's Gibraltar dispute: Centuries of painful conflict
The sovereignty of Gibraltar is a major source of tension between the UK and Spain.
Both in 1967 and 2002, the people of Gibraltar rejected proposals for Spanish sovereignty.
Yet, despite this, Spain still asserts a claim to the territory.
The tension began in 1704 when an Anglo-Dutch force captured Gibraltar from Spain during the war of the Spanish succession.
The territory was then ceded to Britain under the Treaty of Utrecht in 1713.
Historically, it has proved to be an important base for the Royal Navy.
Now, its economy is based on tourism, financial services and shipping.
Under the 2006 constitution of Gibraltar, the territory governs its own affairs although defence and foreign relations are still the responsibility of the UK Government.
Located on the southern end of the Iberian Peninsula, it is an area of 6.8 square kilometres (less than three square miles).