The race to succeed David Cameron as prime minister of Britain was turned upside down on Thursday when Boris Johnson, widely seen as the leading candidate, chose at the last minute not to run, after his close ally Michael Gove challenged him for the job.

The unexpected turn of events was the latest political aftershock from Britain’s vote last week to leave the European Union, and it could benefit another candidate, Theresa May, the home secretary, who laid out her case on Thursday for why she should lead the party.

“Last week, the people of this country voted to take a new path and a new direction for Britain, in a decision that I passionately support,” Mr. Johnson said. “It is vital now to see this moment for what it is. This is not a time to quail, it is not a crisis, nor should we see it as an excuse for wobbling or self-doubt, but it is a moment for hope and ambition for Britain. A time not to fight against the tide of history, but to take that tide at the flood, and sail on to fortune.”…

“Having consulted colleagues and in view of the circumstances in Parliament, I have concluded that person cannot be me,” he said. “My role will be to give every possible support to the next Conservative administration, to make sure that we properly fulfill the mandate of the people that was delivered at the referendum, and to champion the agenda I believe in.”