This map shows all the constituencies that have changed hands in the election, with the colour representing the party that they have switched to.
70 seats switched parties. Labour gained the most new seats, winning a total of 36 seats across the country, and losing only 6, for a total gain of 30. They held on in virtually every marginal where they'd been seen as being under threat, often by huge margins.
The Conservatives have lost the most, with 33, followed by the SNP, who have lost 21. However, the Tories made a lot of their losses back by winning seats elsewhere – they gained 20 seats over the night as well, for a net loss of 13. Among their more notable losses was Ben Gummer, one of the authors of the manifesto that many are blaming in part for the Tories' poor performance.
The SNP, meanwhile, didn't make any gains, ending the night with 35 seats, 21 down from their previous mark. That still makes them the largest party in Scotland, but it's a hugely disappointing result for the party that is significantly worse than the losses the polls had predicted – and includes losing their leader in Westminster, Angus Robertson, and former leader Alex Salmond.
The Liberal Democrats had a mixed night, but one they'll probably be pleased with on balance – they lost 4 of their 9 seats, but gained another 8, increasing their total overall. It means the Lib Dem parliamentary party makeup will be radically different to the last parliament, with former leader Nick Clegg among those losing his seat, although the return of former frontbenchers Vince Cable and Ed Davey will be seen as a success for them.
Elsewhere, Plaid Cymru gained a seat from the Lib Dems, while UKIP failed to win any seats – losing in Clacton, the one seat that it had held before its only MP Douglas Carswell quit the party back in March. The Greens comfortably held on to Caroline Lucas's seat in Brighton Pavilion.
In Northern Ireland's 17 constituencies there were some dramatic changes, with Sinn Féin and the DUP emerging the winners – gaining 3 and 2 seats respectively. The SDLP and the UUP were the losers in this case, also shedding 3 and 2 seats
(One note: It's standard to make these comparisons between general elections, as by-elections can be outliers – which is why Richmond Park, which the Lib Dems won in a by-election in 2016 but was won back by the Conservatives this time, does not appear here. However, Copeland, which the Tories won in a by-election earlier this year and retained in the general election, does appear.)
Here is a full list of all the seats that have changed hands.
Tom Phillips is the UK editorial director for BuzzFeed and is based in London.
Contact Tom Phillips at email@example.com.
Got a confidential tip? Submit it here.