A coalition of rightwing parties will rule Spain's most populous region, Andalusia, for the first time in 36 years under a deal with the far right.
The conservative Popular Party (PP) will rule along with the centre-right Citizens.
Vox, an anti-immigrant party which won seats in Andalusia last year, will not be part of the new government, but has agreed to support the coalition.
The defeat of the left in the southern region has rocked Spanish politics.
Andalusia had been a bastion of the Socialist party (PSOE), which returned to national power last year as a fragile minority government after seven years of PP rule.
Wednesday's deal between the PP and Vox came amid continuing indignation over Vox's policies, with nearly 100 feminist organisations signing a manifesto pledging opposition to the far right's stance on gender equality and violence against women.
What deal was reached?
Actually, there were two deals: Citizens agreed to rule in tandem with the PP, and the PP agreed common ground with Vox in return for that party's votes in the regional parliament.
In the election just over a month ago, the PP won 26 seats and Citizens 21 in the 109-seat legislature, where the absolute majority is 55 seats.
Vox will now make up the voting numbers with their 12 seats.
The PP's Juanma Moreno will lead the new government.
The deal reached between Vox and the PP stipulates 37 goals, the first of which is job creation, then the fight against corruption, followed by respect for democracy.
Andalusia has high unemployment and is the main arrival point in Spain for migrants crossing the Mediterranean.
Other areas of agreement include support for bullfighting and flamenco.
What was left out?
The two parties advocate implementing existing laws on immigration but there is no mention of mass deportations, as advocated earlier by Vox.
Nor is there any mention of repealing laws on violence against women and LGBT equality, which Vox was advocating only on Tuesday.
Vox politicians have often spoken out against what they call "extreme" or "militant" feminism, and argue that domestic violence laws favour women.
The president of Spain's federation of Progressive Women, Yolanda Besteiro, pledged its members would take "not one step back".
"Women's rights are non-negotiable," she said, promising a "continuous mobilisation".