Differences between Spain and the UK over Gibraltar will be resolved by political means not "disproportionate" measures, the Foreign Office has said.
The statement comes after Spanish authorities increased border checks causing delays last weekend.
And on Sunday, Spain said it was considering a new 50 euro (£43) fee to cross its border with Gibraltar.
The UK said it wanted an explanation from Spain about any new measures targeting the British territory.
Gibraltar has been a British territory for 300 years but Spain disputes UK sovereignty over the rocky outcrop on its southern tip.
In the statement the UK reasserted its ties with Gibraltar and said it wanted to continue its strong relationship with Spain.
"The prime minister has made clear that the UK government will meet its constitutional commitments to the people of Gibraltar and will not compromise on sovereignty," a Foreign Office spokesman said.
"Our differences with Spain on Gibraltar will be resolved by political means through our relationship as EU partners, not through disproportionate measures such as the border delays we have seen over the past week.
"We have many common interests with Spain and wish to continue to have a strong relationship at every level with the government of Spain."
It went on: "We will be seeking an explanation from Spain following reports that the Spanish government might target Gibraltar with further measures."
The latest tensions come after the British territory began work on an artificial reef, which Spain claims infringes the rights of its fishermen.
Gibraltar linked Spain's anger over the reef to increased vehicle searches at the border - which resulted in three days of delays last weekend - but Spain denied this, saying it had a duty to prevent smuggling.
In an interview with Spain's ABC newspaper, published on Sunday, Foreign Minister Jose Manuel Garcia-Margallo said Spain was considering the fee to enter and exit Gibraltar through its border post.
He told the newspaper the proceeds would "help fishermen affected by the destruction of fishing grounds".
Mr Garcia-Margallo mooted other measures, including:
- An investigation by Spanish tax authorities into property owned by around 6,000 Gibraltarians in neighbouring parts of Spain
- Closing Spanish airspace to flights headed to Gibraltar
- Changing the law so online gaming companies operating from the British overseas territory have to use Spanish servers and come under the jurisdiction of Madrid's taxation regime
- Stop concrete and other materials to be used for building the reef being brought in through the border
Gibraltar's chief minister Fabian Picardo said "sabre rattling and threatening of the sort attributed to Sr Margallo today [did] nothing for the establishment of strong cross frontier relations".
"The people who live in Gibraltar and in the cities around us clearly wish to live in peace and to benefit from increased economic activity that can be generated from allowing us to work together to deliver growth in jobs and wealth for all the region.
"I therefore trust that the reports we have seen in the Spanish press this weekend remain no more than that," he added.
Gibraltar resident Amber Lyons, 21, said thousands of people who work across the border in Spain would be affected if they had to pay to cross over.
"My boyfriend lives just over the border so I would have to pay 100 euros each time I wanted to see him," said Ms Lyons, who works for the border and coastguard agency.
Ms Lyons, whose grandparents also live close to the Spanish side of the border, added: "I didn't really believe it when I heard it - surely it would contravene our human rights."