The 24-year-old Colombian won two individual stages and completed the 3,479km course 89 seconds ahead of Italy's Damiano Caruso while Briton Simon Yates was third.
The last day 30.3km individual time-trial was won by Bernal's teammate, the time-trial world champion Filippo Ganna, who also won the opening day time-trial.
The Giro win marks a return to form for Bernal who flopped when the cards were stacked against him at the 2020 Tour de France.
"The Maglia Rosa (leader's jersey) is special. It's the most beautiful race in the world's most beautiful place," Bernal said.
"I'll never forget this Giro, and the way I won it, with attacks and sprinting on the flat for bonus seconds against Remco Evenpoel. That is who I am and the cycling I like," said the champion.
The climb specialist who grew up in the Andes took the overall lead on stage nine on a dirt track finish that would have suited this former mountain biker.
He then staged an iconic finish-line triumph on stage 16, stripping off his outer clothing on a cold, rain sodden mountain to cross the finish line first in the pink jersey with his arms wide in acclamation.
It was a similar scene in Milan Sunday as a broad smile swept away his stoney-faced racing look as he raised his arms at the end of three hard weeks where he proved last year's failure was a blip.
Bernal was forced on to the back foot for a few days by a resurgent Yates, but was able to nurse a comfortable lead over the tense last few stages.
For Ineos (formerly Team Sky) it was a third Giro victory after Tao Geoghegan Hart won it in 2020 and Chris Froome in 2018.
- Italian job -
The Giro was the perfect setting for a Bernal comeback given that the rider had made Italy his second home after first arriving in Europe from Colombia.
Ineos leader Dave Brailsford said last season he needed to cut Bernal some slack after the strain of his failed Tour defence so that he could 'get the smile back on his face'.
As the Colombian national anthem blasted out across the Piazza Duomo, Bernal was grinning broadly.
Over the whole three weeks Bernal and Ineos found plenty of fans along the route as Ganna, known to Italian fans as 'Top Ganna', was cheered on by roadside fans, as was the tough road captain Gianni Moscon.
Another Italian, Bahrain-Victorious' Caruso, had never won a grand tour stage victory before but was thrust into the limelight when team leader Mikel Landa pulled out injured.
The 30-year-old Sicilian was given a rapturous reception in front of the Duomo and will be remembered as a journeyman who played his cards right when presented with an opportunity.
Yates said he was happy to be on the podium, but may regret not riding more aggressively in the first two weeks as his tactic of keeping his powder dry for the finale backfired due to Ineos's strength in depth and ability to protect Bernal on his weak days.