Dani Pedrosa edged out MotoGP championship leader Jorge Lorenzo by just over one tenth of a second in the penultimate practice session at Motegi.
It had been Lorenzo who set the pace early on, building on his chart-topping practice one form by dropping down to a 1m46.392s - at the time the fastest lap of the weekend.
As the Yamaha man was flying, Pedrosa looked to be struggling, lapping more than six tenths of a second slower and also suffering an off-track moment.
With 30 minutes to run however the Spaniard suddenly found massive gains, closing to within 0.123s of Lorenzo before jumping to the top of the timesheets with his next lap.
Lorenzo would respond in the final two minutes, improving the benchmark by one hundredth of a second, only for Pedrosa to once again go faster with a 1m46.088s in the final two minutes.
In a mirror of the championship situation, the pair were in a class of their own for most of the session.
That changed in the final minutes, when Andrea Dovizioso, Stefan Bradl and Valentino Rossi were among those to make massive improvements.
Dovizioso's was the most significant, the Tech 3 rider closing to within 0.2s of Pedrosa.
LCR Honda's Bradl meanwhile did enough to snatch fourth from Rossi. The Italian had gone third with four minutes to run, but as others also improved he eventually slipped to fifth.
That still put him ahead of the second works Yamaha and Honda of Ben Spies and Casey Stoner, the pair finishing sixth and seventh respectively.
Gresini's Alvaro Bautista claimed eighth ahead of Cal Crutchlow (Tech 3), Nicky Hayden (Ducati) and Yamaha wildcard entry Katsuyuki Nakasuga.