The United States Grand Prix was won by Max Verstappen, who equaled the record for victories in a season.
Verstappen was in control of the race until a delay at his final pit stop gave Hamilton the lead.
The pit problem gave Hamilton a chance to win a race for the first time in a long time.
The pace of the new world champion was too much, and Verstappen passed Hamilton with six laps to go, the seven-time champion defenceless against the formidable straight-line speed of the Red Bull.
Verstappen's 13th win this year equals the record for wins in a season, held by Michael Schumacher and Sebastian Vettel, and was enough for Red Bull to win the constructors' title for the first time in five years.
Two safety car periods in the middle of the race helped Charles Leclerc finish third, ahead of Red Bull'sSergio Perez and Mercedes' George Russell.
Verstappen dedicated the win to the late co-owner of the team, who died on Saturday.
After the restart from the first, Fernando Alonso's Alpine crashed into the back of Lance Stroll's Aston Martin, causing the second safety car.
Alonso fought back from last place to finish seventh despite his car rearing up into the air at 180mph and crashing down to the track.
Regardless of the outcome of the stewards' inquiry into the incident, it will go down as one of the greatest drives in Alonso's career.
In front of a record crowd at the Circuit of the Americas in Austin, Texas, and a phalanx of celebrities led by Brad Pitt, the race was one of the most exciting events of the year.
After the lights went out, Verstappen took the lead from Carlos Sainz and the Spaniard was taken out of contention in a collision with Russell at the first corner.
The rest of the field fought a series of close battles as Verstappen was in control.
His race looked like it might fall apart when there was a delay fitting his left front wheel.
After sending a radio message to his team, Verstappen was told they were all in it together.
There was nothing that could stop him.
Verstappen told his team they deserved the title double as he spoke over the radio.
Alonso passed Lando on the last lap to take sixth place and the best of the McLarens, while Sebastian Vettel passed Kevin Magnussen on the last lap to take eighth place.