Brad Binder took his maiden Moto2 victory in a dramatic German Grand Prix, while Francesco Bagnaia's points lead was slashed after being forced into a recovery ride by a crashing Mattia Pasini.
The whole field was forced to run the harder front and rear tyres after Dunlop withdrew the soft option on safety grounds due to unusually high track temperatures at the Sachsenring this weekend.
Luca Marini took the holeshot at the start from second on the gird ahead of Sky VR46 teammate Bagnaia and poleman Pasini, while Miguel Oliveira leaped up from 15th to ninth.
Oliveira's charge took a slight knock as he made contact with Xavi Vierge at the final corner, forcing both off line and dropping the Red Bull Ajo KTM rider to 12th.
At the same corner on lap two, Pasini crashed out and forced Bagnaia to run off track in avoidance, dropping the championship leader to 25th.
This promoted Joan Mir and Binder – who signed a new contract to remain with Ajo KTM in 2019 this weekend – up into the podium places, and gifted Marini a lead of over a second.
However, Mir quickly reeled in the race leader and moved ahead of him at Turn 1 on the fifth tour, while Oliveira recovered to sixth ahead of Alex Marquez after his early off.
Binder began his assault for the lead on lap 10, scything past Marini at Turn 1 before putting his KTM up the inside of Mir at the Sachsen Kurve.
Marini regoruped at mid distance and took second back from Mir at Turn 1, while Bagnaia had worked his up to the points paying positions after passing Iker Lecuona for 15th.
Mir usurped Marini once more several laps later and edged away from the Italian, who now had Oliveira closing him down.
With three laps to go, Mir had demolished Binder's lead, and trailed to the South African by just two tenths of a second. However, Binder responded over the final two laps, and held a 0.7s lead across the line for his first Moto2 win.
Mir just held podium debutant Marini at bay for second, while Bagnaia recovered to 12th to keep maintain the championship lead, though fourth for Oliveira has seen the Italian's advantage down to seven points.
Sam Lowes got the better of Marcel Schrotter on the final lap for fifth, with Vierge, Fabio Quartararo and Jorge Navarro completing the top 10 – the latter two having their results decided after a photo finish.
Lorenzo Baldassarri was an early crasher, with Danny Kent, Isaac Vinales, Andrea Locatelli and Tetsuta Nagashima also falling out of contention, while Jules Danilo was forced out on the warm-up lap with a technical issue.