Since Adam Smith and the birth of modern economics, we have learned that barriers are harmful to society. They have a negative impact on companies, deterring competition and limiting us all. The rationale is quite clear: companies, as well as people, need to breath and thrive in larger economic and legal systems where harmonisation and sharing is required.

Last week, Barcelona – the city I hope to become mayor of – hosted the Mobile World Congress (MWC), the biggest industry trade show and a symbol of innovation, globalisation and progress. This year’s theme was intelligent connectivity. Both the separatist movement in Catalonia and Brexit represent the opposite of this – turning their back on this new world of connections and exchange, a world that welcomes the fourth industrial revolution, which will connect us faster, wider and better than ever before. A new world where people, organisations and things will be part of a global liquid society and market with fewer borders and constraints.

Division and exclusion are bad for business and people. After half a century of successful globalisation – measured from any parameter – these counter-movements are pushing for an agenda of separation and nationalism. Brexit and the possible independence of Catalonia from the rest of Spain are different issues, but both share common ground and create worries for the future. It is the latter, however, that would be most serious, for the simple reason that the economic, social and legal ties between Catalonia and the rest of Spain are much stronger and intense than the ones connecting the UK to the European Union.

Pro-independence Catalan flags are waved during a protest against Spanish king Felipe VI’s visit to the Mobile World Congress on 24 February. Photograph: Josep Lago/AFP/Getty Images

It’s no coincidence that approximately half of the exports of the UK and Catalonia are sold to the rest of the EU or Spain respectively. It’s not simply explained by geography either – it is the legal and economic structures of which they are a part. Creating new barriers would damage both economies, the British and the Catalan. Sharing is not only caring: it has always been good for business and individuals. Barriers, either in the form of different regulations, tariffs, judicial systems or banking norms, will always limit our freedom and our choices, and may create higher costs. Brexit or the independence of Catalonia would be lose-lose for all involved, as two jurisdictions compete for taxpayers. In this game, the UK and Catalonia would face tough odds and would stand to lose a lot. As we are seeing in Catalonia, and as happened in Quebec, companies will move and pay taxes in their biggest markets. With them, hundreds of thousands of professionals will also move. The bigger markets, in these cases, are clearly Spain and the EU.

We live in a world of interdependence, connections and solidarity. Political power is multilayered and has far more advantages than disadvantages because it brings a complete system of check and balances and external controls, while also providing companies and individuals a wider space for developing commercially and personally. As Professor Paul De Grauwe of the LSE has explained, in today’s interconnected economies and societies, a formal independence is the opposite of gaining real sovereignty and control. This is because the excluded party would be absent from the table when decisions are made, unable to participate as choices are taken that, sooner or later, will affect them.

The European Union and Spain, particularly, represent successful stories of coexistence, involvement and synergies. Any political decision based on exclusion, lack of solidarity or a false sense of self-governance will only create economic depression and barriers for its citizens. Spain, Europe and the world itself face serious challenges in the coming years. The challenge to build a better world for all of us: a better environment, a better social structure, more opportunities for everyone, a more transparent and yet demanding tax system that really benefits society. That is what I would hope to do as mayor of Barcelona, by building co-operation between the public and private sector, by welcoming entrepreneurs and companies from all over the world to make our great city their home.

• Manuel Valls is a Barcelona mayoral candidate and a former prime minister of France