Bagnaia wins Austrian Grand Prix sprint to join Martin at top of championship
The Italian Ducati rider's victory at the Red Bull Ring in Spielberg moved him up to 250 points, alongside Martin ahead of Sunday's race.
Having clinched pole with a lap record after going fastest in qualifying, Martin was slow getting away when the lights went out while Bagnaia turned on the aggression as soon as he shot off the line.
Martin received a long-lap penalty for failing to lose one second after cutting the chicane at turn two and finished second. He had looked on course to finish third until Marquez crashed out with four laps remaining.
There was no stopping Bagnaia once Martin's penalty had been served and he opened up a sizeable gap over the Spaniard and crossed the finish line well ahead of the chasing pack.
"Incredible, but the most incredible thing is the best lap time we did during battle, a 28.7, that's two-tenths lower than the pole position time last year," Bagnaia said.
"I'm very happy. The fight was intense but then I saw Jorge going wide and I said, okay, be calm there could be a problem for the front tyre.
"But then everything went perfectly, I'm very happy and let's continue like this."
Aleix Espargaro made up a place to finish third and take his second sprint podium. Espargaro, 35, announced in May that he will retire at the end of the 2024 season.
Enea Bastianini, Jack Miller, Franco Morbidelli, Brad Binder, Marco Bezzecchi and Pol Espargaro were the other riders in the points.