Conservative politicians have long declared there is no alternative to capitalism. Many of capitalism’s cruelties, from housing crises and crumbling public amenities to increasingly precarious forms of employment, are most visible in towns and cities. But it’s also in these places that new movements are emerging and rebuilding politics from the bottom up. In cities such as Barcelona, Amsterdam, Berlin and Naples, local activists are defending human rights and public services against a rising tide of anti-immigrant xenophobia and fiscal austerity. We call these urban movements “municipalism”.

By achieving small victories around the world, municipalist movements are proving that there is another way of doing politics – one that begins in the places closest to us. It’s thanks to this movement that someone such as me, a woman from a working-class family who began my political career as a housing activist, can today govern a city such as Barcelona. A tide of municipal movements connects cities across the world, creating networks of alliances and shared objectives. Together, we have put pressure on our national governments and demanded greater powers to fight gentrification, increase the stock of affordable housing, and safeguard our collective right to the city.

In Barcelona we have curbed the Airbnb rentals that drive up demand for a limited housing supply, and have repossessed unused housing owned by banks. The city of Berlin has pledged to freeze rents for five years in an effort to halt gentrification. New York City has promised to divest $5bn from fossil fuels and to sue oil companies for their contribution to global warming. These small victories show that alternatives to our dominant economic system are within reach – and that cities are a key part of this future.

This doesn’t mean urban politics is without challenges. There’s a risk that we’ll be reduced to resolving quotidian problems and fall short of our ambition to confront systemic crises. Though cities will be central to the transition towards a fossil fuel-free future, the climate emergency doesn’t respect borders, and demands networked, international solutions. For this reason, it’s crucial that the climate emergency declarations made in cities including Barcelona, Amsterdam and New York transcend mere symbolic gestures – and that we hold our national leaders to account.

What does municipalism have to do with the future of Europe? Everything. Europe has been immersed in a crisis of legitimacy for the past decade. The EU has functioned as a single market, but not as a joint democratic project. It has suffered from a lack of citizen participation, with a distanced parliament and a cruel migration policy that has violated human rights and betrayed the principles of solidarity agreed by Europe’s leaders in the wake of the second world war. Part of our work in Barcelona has been to develop an approach to migration that protects the rights of residents in our city, and their access to public services, regardless of their immigration status. We firmly believe that border crossings should be places of meeting and welcome, not of death.

Europe can only be strong if it is capable of reinventing itself from the bottom up. To secure its future, Europe must recommit itself to its founding values: the guarantee of human rights and democracy. Today, the politics of hate and xenophobia are the main threats to the values that the EU once espoused. We urgently need to avert their spread and build societies that are fair, inclusive and diverse. The municipal movements in cities across Europe are already building networks of solidarity that will be essential in fighting the political forces threatening the union, and in resisting the siren call of the far right. It is my deep conviction that there is no greater power than that which is built by people working together at the grassroots, and that our neighbourhoods, towns and cities are the only places where this can happen.

• Ada Colau is the mayor of Barcelona