On first glance, there might not seem to be that much in common between Barcelona and Edinburgh.

But one thing the Scottish and Catalan capitals share is that they are both highly sought-after European tourist destinations.

Each year, they receive millions of visitors - around ten times more than their cities' respective populations.

Tourists reportedly generate around £1.3bn annually for Edinburgh's local economy and help support 30,000 jobs.

As the council has unveiled plans to bring in a tourism tax, questions have arisen about the potential effect on visitor numbers, and whether the move would hit the city in the pocket.

STV News took a trip to Barcelona to find out what sort of impact a similar levy, introduced in 2012, had on the city.

Barcelona is a city with 1.6 million inhabitants and receives around 15 million tourists every year.

Including those who only stay overnight, this figure rises to around 28 million people.

To try and manage this level of tourism, maximise its benefits and reduce its negative impact for locals, officials imposed a €2.50 nightly charge on all tourist accommodation - from five-star hotels to apartments to camper vans.

"It is an income that the city gets and a way for citizens to see that tourism also benefits them," explained Agustí Colom, councillor for tourism, commerce and markets in Barcelona.

"With the tax, we don't only fund services connected to tourism, but also community projects, for instance, musical festivals and the restoration of cultural heritage.

"It's a way that the citizen sees that tourism can benefit them."

In Edinburgh, similar proposals for a tourism levy have been with fierce resistance by firms reliant on the industry, with tycoon Richard Branson also voicing opposition.

A recent survey showed that 76% of local businesses were against the introduction of a levy on tourism, and 73% said they thought it would have a negative impact on the local economy.

They fear that visitor numbers will fall as tourists are "priced out" of the city and go elsewhere.

But in Barcelona, officials and tradespeople tell a different story.

"The tourist tax works," Mr Colom told STV News.

"Since its implementation, tourism hasn't diminished.

"The tax is a very small amount in comparison to what every tourist spends in the city, so it doesn't affect the arrival of tourists."

Manel Casals, director general of the Barcelona hoteliers association, concurs with this assessment.

"We haven't noticed a reduction of the amount of people visiting the city after its implementation," he said.

However, he said the tax had caused hoteliers' profits to suffer.

"If we talk specifically about the hotel industry, we have seen a direct impact on the tax on hoteliers' profits," Mr Casals explained.

"This tax has not represented a price increase for the tourist, but rather a reduction in the hotels profits.

"In other words, the two or three euro that the tourist should be paying, beyond the cost of its room, has actually meant that the hotel has drop the price of the room by this amount, reducing its profits."

Another problem, he told STV, is the rise of "illegal" accommodation which avoids the tax, such as some apartments rented via Airbnb.

The tourism levy has not yet managed to lift the problems for locals associated with large numbers of visitors, such as overcrowding, congestion, and rising house prices.

And for tourists - going by the evidence in Barcelona - it would seem the tax has done little to dissuade them from visiting the city in their droves.