Dumoulin and the German-registered team made the announcement during a special event at the Sunweb headquarters.
Telesport.nl reported during the final days of the Giro d'Italia that the contract would be signed soon, despite apparent interest from Team Sky. Dumoulin's current contract runs through 2018, and this new deal will be one of the longest big-name contracts in professional cycling.
Dumoulin confirmed the news in a video posted on the team's website.
"I have some big news for you. I decided to renew my contract with Team Sunweb until 2022, so for coming four years I'll still be riding in our great team colours," he said.
"I've always been happy with the team, and I made some huge steps in my development, not only me but the whole team grew to another level in the past years. I'm very confident that we will be making huge steps still in the coming years. I feel really good in the team and I'm really looking forward to the coming four years."
Early on Tuesday, Team Sunweb confirmed that Dumoulin would line up alongside Michael Matthews at the Tour de Suisse. He will not ride the Tour de France but is likely to target the Vuelta a Espana.