George Russell became the first Mercedes driver to win a grand prix when he took the chequered flag at the Brazilian GP.
After Verstappen and Hamilton fought for second place at a safety car restart, Russell was in control of the race.
After a difficult season that started with an uncompetitive car, Hamilton came back to secure a Mercedes one-two and seal the team's recovery after he dropped to ninth.
Russell's accomplished drive included him surviving a late safety car that bunched up the field and put Hamilton behind him heading into the final 10 laps.
The Mercedes drivers were told that they could race, but Russell held the lead at the restart and kept Hamilton at bay.
A number of drivers who had had difficult races revived their afternoons behind them.
After the Verstappen-Hamilton incident, McLaren's Lando Norris barged off the track and Verstappen himself dropped to the back.
At the restart, Leclerc was sixth but moved up to finish fourth behind Sainz and Perez.
After starting 18th, Fernando Alonso overtook the Mexican to take a fifth place.
Verstappen failed to pass Alonso on a race to the line, but the late caution period helped him move up from the bottom of the top 10 to sixth place.
After being allowed past a few laps earlier, Verstappen was told to let Perez back past, but he didn't comply.
After the race, he was asked what happened. He said, "You guys don't ask that again to me, okay?" We are clear about that. I stood by my reasons.
Mercedes went into the race with a front-row lock-out - after Russell's win in the sprint race on Saturday and a grid penalty for Sainz, who had finished second behind Hamilton - but worried about the potential pace of Verstappen.
They had to do it again a few laps later after holding their positions at the start.
Verstappen dived for the outside into Turn One after running into Hamilton at the start of the race.
They collided while trying to negotiate Turn Two side by side.
Verstappen was given a five-second penalty for complaining that Hamilton had not left him enough space.
After managing his pace for the first few laps the Englishman obeyed a request from the team to up his pace and build a gap and Perez had no answer.
As Russell took control of the race, it became apparent that Hamilton had a chance of second, as he was able to climb back up the field in his recovery.
Hamilton ran a bit longer on his first set of tires. After stopping six laps later than Perez, he came in fourth place.
Sainz's race was disrupted early on when a visor tear-off got caught in a rear brake duct, and Hamilton overtook Perez with 26 laps to go.
The virtual safety car and the safety car were deployed when the McLaren stopped on the track.
The result was dependent on who had the most fresh rubber.
Perez, who had made his last stop earlier than others and fitted medium tyres rather than softs, was left vulnerable and he succumbed to Saiz, then Leclerc and then Verstappen, who he was ordered to let by so the world champion could try to take points off those
Verstappen made no further progress, leaving the Red Bulls sixth and seventh.