Pinot, of the Groupama-FDJ team, soloed over the finish line at Lake Como to win the 241 km-long 'Race of the Falling Leaves', which began in Bergamo.
Italy's defending champion Nibali (Bahrain) finished second at 30 seconds behind, with Belgian Dylan Teuns (BMC) third at 43 seconds.
“To win here in front of Vincenzo, I couldn't have dreamed of better!” said the 28-year-old climbing specialist, who also won the Milan-Turin semi-classic in midweek.
He becomes the first French winner of the race since Laurent Jalabert 21 years ago.
Pinot finished third in 2015 and fifth in 2017 – the years when Nibali, 33, who has won all the Grand Tours, was victorious in the race through northern Italy.
“Among the monuments, Il Lombardia is the nicest in my mind,” continued Pinot.
“I've always wanted to win it. I'm in the form of my life but to win ahead of Nibali is something very special.
“It's my most beautiful victory. I'm glad he attacked at Sormano. That was the key to success.”
'My legs said no'
“I always give the maximum but today my legs said no,” said Nibali. “Pinot was in extraordinary form.”
Under the sunshine, the race sprung to life after 50km at the Muro di Sormano, where Nibali and Pinot overtook Lotto's Primoz Roglic who had led going into the very steep climb.
“When I saw Nibali attack on the Sormano, I said to myself 'bingo, it's a good move',” explained Pinot. “Vincenzo is a unique rider. Few would have done like him.”
The pair, joined by Roglic, powered ahead in the descent, along with young Colombian Egan Bernal.
A group including newly-crowned world champion Alejandro Valverde trailed at 40 seconds without being able to close the gap.
As in last year's race, Pinot and Nibali proved strongest at the Civiglio, the 4.2km penultimate climb, 15km from the line, where the pair shook off their rivals.
The French rider broke away from the Italian at the summit to pull 20 seconds ahead, extending his lead over the three kilometre drop to the finish line at Como.
“After that, it was pedalling, it was a great duel with Vincenzo,” added Pinot.
“I'm not thrilled to finish second but it's okay,” said Nibali.
“After what happened to me in July (fall on the Tour de France because of a spectator), I can even say I'm happy to be here.”
Teuns was third among a group of riders including Colombian Rigoberto Uran, with Spaniard Valverde trailing home in 11th.
For Pinot it was a dream finish to a rollercoaster season after being hospitalised the night before the Giro d'Italia finish, when he had been in third place, diagnosed with pneumonia.
He missed the Tour de France, but won two stages of the Tour of Spain, now lifting his first 'Monument' trophy, by the biggest winning margin in 22 years.