Speaking outside 10 Downing Street, he said"fresh leadership" was needed.
The PM had urged the country to vote Remain but was defeated by 52% to 48% despite Scotland, London and Northern Ireland backing staying in.
UKIP leader Nigel Farage hailed it as the UK's "independence day", while Boris Johnson said the result would not mean "pulling up the drawbridge".
Scottish First Minister Nicola Sturgeon said she was "absolutely determined" to keep Scotland in the EU so a second Scottish independence referendum was now "highly likely".
German chancellor Angela Merkel expressed "great regret" at the outcome, and EU chiefs said they expected the UK to begin negotiations to leave "as soon as possible, however painful that process may be".
But Boris Johnson, the ex-London mayor and public face of Vote Leave who is now a front-runner to be next prime minister, said there was "no need for haste" about severing the UK's ties.