The deal will see Hamilton partner with Mercedes for a ninth season and puts an end to months of speculation over the Briton’s immediate future in the sport.
Hamilton has dominated the F1 landscape since joining Mercedes from McLaren in 2013, winning 74 races as well as six drivers’ championships.
He set up a commission in his name to increase diversity in motorsport with the hope of making “real, tangible and measurable change.”
Mercedes said the new deal would include a “joint commitment for greater diversity and inclusion.”
“I am excited to be heading into my ninth season with my Mercedes teammates,” said Hamilton.
“I’m equally determined to continue the journey we started to make motorsport more diverse for future generations and I am grateful that Mercedes has been extremely supportive of my call to address this issue.
“I’m proud to say we are taking that effort further this year by launching a foundation dedicated to diversity and inclusion in the sport. I am inspired by all that we can build together and can’t wait to get back on the track in March.”
Hamilton will bid to win a record-breaking eighth world title when the 2021 season begins in Bahrain on March 28.
Analysis by CNN Sport’s Amanda Davies
So the deal has finally been done — the last remaining driver’s seat for the 2021 campaign filled.
Interestingly, Hamilton’s deal is only for one season, and not for two, like Lewis’ previous contracts with Mercedes.
It certainly gives both sides options moving forward, but before that, sees the real prospect of Lewis claiming that record-breaking eighth F1 world championship.
And as we saw increasingly during 2020 — with the establishment of a new joint charitable foundation to help create “greater diversity and inclusion in motorsport” — Mercedes continues to lead from the front as a team on those issues, while Lewis has his sights set on winning more than just trophies.