Marquez's redemption arc played out perfectly at the Circuit de Barcelona-Catalunya, where he crashed out of a commanding lead in last year's sprint, allowing brother Marc to take the chequered flag.
This time, however, Alex Marquez held his nerve in a nail-biting duel with pole sitter Acosta to claim his first sprint victory of the season.
"I was trying to concentrate on myself, trying to be really on the pace," Marquez said.
"I struggled a little bit with the front tyre in the end, maybe I pushed a little bit too much in the beginning.
"So I need to improve for tomorrow in the management of the front tyre. But in the end, a victory today is also important."
At the start, Acosta shot into the lead and defended his position well while LCR Honda's Johann Zarco, who has never finished on the podium in a sprint, carved his way through to move up from fourth to second.
But Marquez was the early pace-setter, finding his way past veteran Zarco before using his compatriot Acosta's slipstream to seize the lead on lap four.
Jorge Martin's bid to seize the championship lead ended in the gravel after a costly mistake when the Aprilia rider crashed out at turn 10 -- his fourth fall of the weekend -- with marshals urging the desperate Spaniard not to rejoin the sprint.
Acosta appeared to be fading as even Trackhouse's Raul Fernandez swept past the 21-year-old KTM rider, leaving him scrambling to defend the final podium spot against a charging Di Giannantonio.
But the youngster found a second wind with four laps remaining, reclaiming second from Fernandez.
Two laps later, Di Giannantonio moved up to third to put two Ducati bikes in podium places but he kept a safe distance behind Marquez and Acosta as the two Spaniards battled it out for the lead until the finish line.
"We know that, at the moment, we are not in the level of Ducati," Acosta said.
"We were, at the end of the race, finally battling with them. For this we have to be happy."
Championship leader Marco Bezzecchi finished ninth to take only one point while Martin now sits two points behind his Aprilia teammate going into Sunday's race.
