Image copyright Getty Images Image caption Mark Drakeford defeated Vaughan Gething and Eluned Morgan in the contest
Mark Drakeford is set to become Wales’ next first minister after winning the Welsh Labour leadership election.
The pro-Corbyn finance secretary, who secured 53.9% of the vote after the count went to a second round, pledged to make Wales “a beacon of hope in a darkening world”.
He is expected to replace Carwyn Jones at the helm of the Welsh Government when he stands down next week.
Vaughan Gething came second with 41.4% of the vote. Eluned Morgan was third.
Deputy Welsh Labour leader Carolyn Harris revealed the election result at the Cardiff Principality Stadium on Thursday, after a contest that lasted eight months.
Carmarthen-born academic Mr Drakeford, 64, has pledged to extend the smoking ban to town and city centres, and give the parents of newborn babies a bundle of essential items.
Around 175,000 people had the right to vote – including around 25,000 party members and others who are part of affiliated trade unions.
Media playback is unsupported on your device
Media captionMark Drakeford pledges a brighter future for Wales
Once confirmed, Mr Drakeford will take the helm of the Welsh Government, which has responsibility for health, education, transport and some taxation.
As well as dealing with the Welsh response to Brexit, Mr Drakeford will be faced with whether to reshuffle his ministers, and whether to go ahead with building the M4 relief road south of Newport.
By Felicity Evans, BBC Wales political editor
Image copyright Getty Images Image caption Mr Drakeford is congratulated by supporters after his election on Thursday
Mark Drakeford is the ultimate government insider – an adviser to the late former first minister Rhodri Morgan before succeeding him as the AM for Cardiff West and holding a variety of senior positions at cabinet level.
But while he is well known in political circles, many voters have never heard of him. This will be a challenge for him.
He was always the front runner, but this result is closer than many people expected. He had the bulk of the support from Labour’s big institutions, including Momentum – which has swelled the ranks of Welsh Labour members in the last couple of years.
This result is not the resounding victory many predicted. One senior Labour figure and Drakeford supporter whispered to me: “That was close.”
Another said: “A win’s a win”.
“Who can remember what Carwyn’s margin of victory was nine years ago?”
Image copyright Campaign handout Image caption Mark Drakeford (L) has described the late Rhodri Morgan (R) as his mentor
Mr Jones announced in April he would step down by the end of 2018 –