Watch: Sunak's resignation speech in full
Six weeks after calling a snap election, the PM was back in a wet Downing Street to confirm he was leaving the job.
After losing 250 Conservative seats on Thursday night, Rishi Sunak said he was "sorry" for the result and that he would stand down as party leader, but not immediately.
Speaking for the last time in public as prime minister, he said the UK was "safer, stronger and more secure" than it was before he took office.
The Tory leader said his successor Sir Keir Starmer was a "decent public-spirited man whom I respect".