Jacinda Ardern is quitting as New Zealand prime minister ahead of this year's election saying she no longer has "enough in the tank" to lead.
The shock announcement comes as polling indicates her Labour Party faces a difficult path to re-election on 14 October.
Ms Ardern choked up as she detailed how six "challenging" years in the job had taken a toll.
Labour MPs will vote to find her replacement on Sunday.
Ms Ardern, 42, said she had taken time to consider her future over the summer break, hoping to find the heart and energy to go on in the role.
"But unfortunately I haven't, and I would be doing a disservice to New Zealand to continue," she told reporters on Thursday.
Ms Ardern will step down by 7 February. If no would-be successor garners the support of two-thirds of the party room, the vote will go to Labour's lay membership.
Ms Ardern became the youngest female head of government in the world when she was elected prime minister in 2017, aged 37.
And a year later she became the second elected world leader to ever give birth while in office, after Pakistan's Benazir Bhutto in 1990.
She steered New Zealand through the Covid-19 pandemic and its ensuing recession, the Christchurch mosque shootings, and the White Island volcanic eruption.
Ms Ardern said the past five-and-a-half years had been the "most fulfilling" of her life, but leading the country during the "crisis" had been difficult.
"These events... have been taxing because of the weight, the sheer weight and continual nature of them. There's never really been a moment where it's ever felt like we were just governing."
National Party leader Chris Luxon was among those who thanked Ms Ardern "for her service to New Zealand".
"She has given her all to this incredibly demanding job," the opposition leader wrote on Twitter.
Australian Prime Minister Anthony Albanese described Ms Ardern as a leader of intellect, strength and empathy.
"Jacinda has been a fierce advocate for New Zealand, an inspiration to so many and a great friend to me," he wrote.
Canada's leader Justin Trudeau said she had made an "immeasurable" difference to the world.
But while Ms Ardern was often seen as a political star globally, opinion polls suggest she was increasingly unpopular at home.
She led the Labour Party to a landslide election victory in 2020, capitalising on her government's strong early response to the pandemic.
But the latest opinion polls put her personal popularity at its lowest since she was elected, and approval of her party's performance similarly low.
In 2022, Ms Ardern told the BBC her declining popularity was the price her government had paid for keeping people safe from Covid-19.
However, she has also been confronted with a cost-of-living crisis, national fears about crime, and a backlog of election promises put off during the pandemic.
Reaction to her announcement has been varied. One local from her own Auckland electorate told the NZ Herald Ms Ardern was "running away before getting thrown out", blaming her for increased crime and rising living costs.
For others, like Auckland Pride's Max Tweedie, she is "one of the greatest prime ministers in New Zealand's history".
Those are sentiments shared by New Zealand actor Sam Neill, who said Ms Ardern had faced "disgraceful" treatment from "bullies" and "misogynists".
"She deserved so much better," the Jurassic Park star wrote on Twitter.
But Ms Ardern stressed that she was not resigning because she and the party were unpopular.
"I am not leaving because I believe we can't win the election but because I believe we can and will, and we need a fresh set of shoulders for that challenge."
Contenders for the job are yet to emerge, but several MPs - including deputy leader Grant Robertson - have ruled themselves out of the contest.
Ms Ardern listed her government's achievements on climate change, social housing and reducing child poverty as ones she was particularly proud of.
But she said she hoped her legacy in New Zealand would be "as someone who always tried to be kind".
"I hope I leave New Zealanders with a belief that you can be kind, but strong, empathetic but decisive, optimistic but focused. And that you can be your own kind of leader - one who knows when it's time to go," she said.