On Twitter, most celebrities grieved. Brexit opponents included Harry Potter author JK Rowling, TV host James Corden and The Sandman creator Neil Gaiman.
Goodbye, UK. https://t.co/HMRA0AnlWR? J.K. Rowling (@jk_rowling) June 24, 2016
Scotland will seek independence now. Cameron's legacy will be breaking up two unions. Neither needed to happen. https://t.co/4MDj7pndcq? J.K. Rowling (@jk_rowling) June 24, 2016
I can't get my head around what's happening in Britain.I'm so sorry to the youth of Britain. I fear you've been let down today x? James Corden (@JKCorden) June 24, 2016
I am afraid you are going to need it,
Neil. ? Neil Gaiman (@neilhimself) June 24, 2016
House and The Night Manager star Hugh Laurie was more cautious.
An amazing turnout. Wherever we're headed, it's not with a whimper.? Hugh Laurie (@hughlaurie) June 24, 2016
Congratulations exiters. Reverse is across and down, easy on the clutch.? Hugh Laurie (@hughlaurie) June 24, 2016
Elizabeth Hurley, who voted to Leave, tweeted midway though the counting of votes:
And suddenly the birds are singing.....still glued to the TV though #Brexit? Elizabeth Hurley (@ElizabethHurley) June 24, 2016
Indian celebrities mostly expressed dismay.
A victory for fear and isolationism. Is this the beginning of the break up of the European Union? #Brexit? soha ali khan (@sakpataudi) June 24, 2016
If there was anymore evidence needed the world has gone mad. #Brexit 'Keep Calm And Stab Yourself'.? Rahul Bose (@RahulBose1) June 24, 2016
'Tis the summer of our discontent #Brexit? Lisa Ray (@Lisaraniray) June 24, 2016
Divide and rule #Brexit? Shoojit Sircar (@ShoojitSircar) June 24, 2016
Kabir Bedi alone was uplifted by the result:
The funniest Brexit tweet was posted by, naturally, Shah Rukh Khan, two days before the referendum:
I c this trend in News where leaving of someone or something is headlined as Rexit or Brexit.So if I leave from sumwhere am I Sexit??? Shah Rukh Khan (@iamsrk) June 22, 2016
Britain will be the first country to leave the EU since its formation - but a leave vote will not immediately mean that Britain ceases to be a member of the 28-nation bloc.
That process could take a minimum of two years, with leave campaigners suggesting that the referendum campaign may not be completed until 2020, the date of the next scheduled general election.