Nigel Farage has resigned as Ukip leader after finishing second in Thanet South, telling activists "I'm a man of my word" after promising defeat would force him to quit.
But Mr Farage raised the prospect he would consider running to return to the job after a summer off when the contest is held in September.
Mr Farage said he would recommend Suzanne Evans, the deputy chairman, be a stand-in leader until the leadership challenge is complete.
Nigel Farage has insisted he has "never felt happier", with a "weight lifted off his shoulders", after finishing as runner-up in his constituency and failing to get a Westminster seat.
Half an hour before he announced his resignation, he insisted he had "never felt happier", with a "weight lifted off his shoulders", after finishing as runner-up in his constituency and failing to get a Westminster seat.
Conservative Craig Mackinlay won by almost 3,000 votes.
Mr Farage, who vowed to resign as Ukip leader if he failed to enter the Commons, polled 16,026 votes.
But the Tory candidate did better, winning the backing of 18,838, with Labour third.
In his concession speech, the Ukip leader did not resign.
He said: "On a professional level, I express today a degree of disappointment. On a personal level, I feel an enormous weight has been lifted from my shoulders.
"I have never felt happier."
Announcing his resignation, he said: "I'm a man of my word, I shall be writing to the Ukip national executive in a few minutes, saying I am standing down as leader of Ukip.
"I shall recommend that ... they put in place as acting leader Suzanne Evans who I think has emerged from this campaign as an absolute tower of strength within Ukip."
He added: "Personally, there's a bit of me that is disappointed but there is a bit of me that feels better than I have felt for many, many years.
"It really has been seven days a week, totally unrelenting, and occasionally let down by people who perhaps haven't said and done the right things.
"I haven't had a fortnight's holiday since October 1993. I intend to take the summer off, enjoy myself a bit.
"There will be a leadership election for the next leader of Ukip in September and I will consider over the course of this summer whether to put my name forward to do that job again."