The defending world champion was only fifth on the grid in his Yamaha, but worked his way to second place before catching and passing points leader Casey Stoner six laps from home to move within 19 points of the Repsol Honda rider in the standings.
Stoner has been the dominant force in the series in recent rounds, racking up three wins and a second place in the previous four races, and led for the first 17 laps.
But the warm temperatures saw his tyres suffer and he even missed out on second place when team-mate Andrea Dovizioso found a way by on the final lap.
The day belonged to Lorenzo and the Spaniard was in no doubt where the victory ranked in his career.
He said: "I pushed and tried to be there with all of my heart. I tried to overtake Andrea in the downhill at the chicane and then I did the same with Casey because I thought it was the perfect corner for it.
"Now we have a competitive bike and I hope to keep this pace. Now I am more motivated and confident for the future after this great result.
"I think it was one of my most demanding races of my career. It reminded me a bit if my time in the 125cc class, with many overtaking moves.
"I did a good start again and now I just want to watch the race again on TV."
Ben Spies followed up his win in Assen with a solid fourth place, with Marco Simoncelli staying out of trouble to take fifth on his Gresini Honda.
Valentino Rossi, so often the master of Mugello, could only trail home sixth as Ducati continue to struggle for pace, with Hector Barbera seventh and Dani Pedrosa a brave eighth on his return from a broken collarbone.
The American duo of Colin Edwards and Nicky Hayden rounded out the top 10, but Britain's Cal Crutchlow failed to finish due to set-up problems with his Tech 3 Yamaha.