Last week, the European Union angered the UK by describing Gibraltar as a “colony of the British crown.”

The comment was made in proposed regulation that could see Britons granted visa-free access to the EU even in the case of a no-deal Brexit. The bloc made a distinction between those living in the UK and citizens of Gibraltar, a British overseas territory disputed by Spain.

This is not the first time, Gibraltar has been a point of controversy in Brexit negotiations. Last year, Spain’s prime minister, Pedro Sanchez, said that his country would reject the Brexit withdrawal agreement if plans for future talks on the status of Gibraltar were not clarified.

But what can Gibraltar’s history teach us about the role the 6.7 km2 British overseas territory at the southern tip of the Iberian Peninsula has played so far during Brexit negotiations?

Gibraltar was Spanish at one point

After centuries of being controlled by different kingdoms, Gibraltar finally came to be in Spain’s power in 1462 when it was captured by Juan Alonso de Guzman, the first Duke of Medina Sidonia. Henry IV of Castile assumed authority over the territory and made it part of the Campo Llano de Gibraltar county, in the most southern part of Spain.

But the Spanish reign over Gibraltar lasted less than 300 years when an Anglo-Dutch fleet captured Gibraltar in 1704. A decade later, Gibraltar became British after the Treaty of Utrecht was negotiated to end the war of the Spanish Succession.

Several unsuccessful attempts from Spain to regain control of Gibraltar were made but the territory's tutelage never changed again.

In the coming decades, Gibraltar became an important navy base for Britain due to its strategic location.

A cloud partially covers the tip of the Rock of the British territory of Gibraltar at sunrise from La Atunara port before Spanish fishermen sail in their fishing boats with their relatives to take part in a protest at an area of the sea where an artificial reef was built by Gibraltar using concrete blocks, in Algeciras bay, La Linea de la Concepcion in southern Spain August 18, 2013 REUTERS/Jon Nazca/File Photo

WWII everything changed

In the first half of the 20th century, Gibraltar spoke mostly Spanish and was culturally closer to Spain than to the UK but by the end of the century, Gibraltarians felt more politically and culturally British, said Andrew Canessa, a sociology professor at University of Essex and author of the research project Bordering on Britishness: An Oral History of Gibraltarian Identity in the 20th Century.

So how did this shift in mindset happen?

During WWII, most of Gibraltar’s civilian population was evacuated to London so the territory could be fortified against a German attack. By 1942, there were over 30,000 British soldiers, sailors, and airmen in Gibraltar.

After the war ended, Gibraltar overwhelmingly voted to continue their association with the UK after Spanish dictator Francisco Franco restricted movement between Gibraltar and Spain in the 1960s.

In retaliation, Spain completely closed the border with Gibraltar and cut all communication links. The border was reopened once again in 1985 before Spain joined the European Economic Community.

People walk past drinks and tobacco store at Main street in the British overseas territory of Gibraltar, historically claimed by Spain, November 25, 2018. REUTERS/Jon Nazca REUTERS/Jon Nazca

In post-war years, the territory also went through important education reforms that saw schools start teaching in English.

"These two things, the UK's policy of turning Gibraltarians into British people and the state of hostility from Spain pushed Gibraltarians closer to the UK culturally and politically," said Canessa.

The 16-year-old closure of the border between Gibraltar and Spain also oriented Gibraltarians towards the UK, he added.

Thirty-five years later, Gibraltar reaffirmed their desire to remain solely British after overwhelmingly rejecting a proposal of shared sovereignty between Spain and the UK.

What do Spanish think about Gibraltar?

According to Canessa, Spanish opinions towards Gibraltar are divided between older and younger generations.

The first one, that of older Spanish women married to Gibraltarian men who have a profound hostility towards the Franco regime consider themselves to be from the territory.

Then, there is that of younger post-Franco generations who often live in La Linea (the Spanish town across the border) and who work in Gibraltar.

"There are some who tend to look at the commonalities (between the two places) while others ignore Gibraltar's history and see it as a culturally British place," he said.

"So there are those who see Gibraltar as a source of employment and those who see it as a source of under-development."

Passengers cross the border to enter Spain as they leave the Gibraltar International airport due to adverse weather conditions to flight in the British overseas territory of Gibraltar, historically claimed by Spain, November 25, 2018. REUTERS/Jon Nazca

What do British people in the UK think about Gibraltar?

Most people in the UK don't have an opinion about Gibraltar, said Canessa, adding that many people don't know it even exists.

But "people who know it exists see it as this place full of nostalgia of Britishness. They see this hyper-British place, a place where you can imagine a British past," he said.

And what about native Gibraltarians? Do they have a sense of national identity?

Canessa told Euronews that since the 1990's there's been a conscious development of nationalism in Gibraltar — one that isn't British or Spanish.

But Canessa, who's a native Gibraltarian himself, talked about the locals' concern over Brexit.

"Until recently, Gibraltar was an issue between two EU member states and the EU itself was neutral. Now, it is between Spain, an EU member, and a third-party. And increasingly over the last week, there’s been indications that the EU is starting to take Spain’s side," said the professor.

"Gibraltarians are very worried about what Spain’s intentions are. Due to this recent nationalism, Gibraltar likes to see itself as a nation rather than a colony."

"The two pillars of Gibraltar’s Britishness are economic and political security and Brexit threatens both of these," he added.

The territory is due to leave the EU along with the UK in March 2019.