Barry Thomas replaces David Jones as Powys Council's new leader
A political battle at Powys Council has led to leader David Jones being ousted in a vote of no confidence.
Former council chairman Barry Thomas will succeed him after a meeting in Llandrindod Wells.
The political unrest is set against a background of the council looking to make £20m budget savings in the next financial year.
The council is traditionally controlled by independents but there has been a power struggle in recent weeks.
Mr Jones wanted to bring forward a new ruling coalition group, which ended in him axing three cabinet members who opposed it at the end of November.
He defended the sackings by saying a stronger and united authority to tackle budget pressures was needed.
He then joined another independent group and formed a new cabinet before he faced Friday's leadership challenge.
It is believed to be one of only a couple of times a Welsh council leader has lost a vote of no confidence in their leadership.
Mr Jones, who had been leader for 19 months, was toppled from his job as council leader by 40 votes to 32 by councillors on Friday.
Members then went on to elect Mr Thomas - a former council chairman and the member of another independent group - as new leader.
He beat off the challenge of Mr Jones' former deputy cabinet leader Tony Thomas by 41 votes to 30 in the leadership race.
Myfanwy Alexander had been knocked out in the first round.
The new leader, a member of the six-strong Non-political group, has dissolved the existing cabinet which had consisted of 10 members of the Powys Independent Alliance group led by Tony Thomas.
He will announce a new cabinet by next Wednesday.
Traditionally, the majority of Powys council candidates stand as independents and those elected come together after polling day to form groupings and an administration.
Friday's extraordinary meeting followed a split from the ruling group.
Members of the new Independent Group (IG) claimed Mr Jones no longer had a mandate to lead the council.
Mr Jones had axed Ms Alexander, Graham Brown and Garry Banks from his cabinet on 26 November.
The three councillors were from the group he previously led, the Shire Independent Group. They defected with others to form the Independent Group (IG) led by Mr Brown.
The no confidence motion was launched by Mr Brown and fellow IG member, Ms Alexander in the wake of Mr Jones's decision to join the Powys Independent Alliance (PIA) in December, which until Friday held all 10 cabinet posts.
Powys council is facing budget cuts of £40m over three years.
In December it announced a four-pronged approach to tackle a £20m funding shortfall in the next financial year which could lead to 300 job losses.
The plan includes service cuts, a possible hike in council tax, and increasing service charges.
It also aims to replace some staff by providing automated services.