Hamilton drew level with Michael Schumacher on 91 wins at the Eifel Grand Prix in Germany earlier this month.
And the world champion will now start as the favourite to make history here in the Algarve on Sunday after seeing off Mercedes team-mate Valtteri Bottas’ challenge by just 0.102 seconds with his final lap of a nail-biting session.
Red Bull’s Max Verstappen will line up from third, one place ahead of Ferrari driver Charles Leclerc.
The running on F1‘s first jaunt back to Portugal in 24 years was delayed by 30 minutes following repair work to a dislodged drain cover on the exit of the penultimate corner.
Track marshals laid down fresh tarmac to keep the loose metal in place, and scoured the 2.89 miles of track for additional ill-fitting drains.
But when the action eventually started, it looked as though it would be Bottas who would carry over his fine practice form to secure his second pole in as many races.
The Finnish driver headed into qualifying with a practice cleansweep under his belt, but Hamilton executed a different strategy in Q3 by completing one extra lap than his team-mate, and taking pole.
“I cannot tell you how hard that was today,” said Hamilton after securing his 97th career pole. “We have got a great car but you have to drive the nuts off it to pull out a lap.
“I have just been digging and digging to find that extra time. I did three laps to give me a stab in the final session at beating Valtteri’s time.
“He decided to do one and it provided me with an opportunity and it worked. That last lap just got better and better.”
George Russell’s future has been the source of much speculation here after it emerged that he could be replaced by Sergio Perez at Williams next year.
Williams have recently been acquired by Dorilton and the belief is that they want drivers who bring cash to the British team, putting Russell’s 2021 seat in danger.
Here, the 22-year-old Mercedes junior delivered another fine one-lap performance to extend his undefeated qualifying streak over his team-mates – Robert Kubica in 2019 and Nicholas Latifi this year – to 33.
Russell sealed his passage through to Q2, lapping a full second faster than his team-mate, before finishing 14th, one spot ahead of four-time world champion Sebastian Vettel in his Ferrari.
The sooner Vettel leaves Ferrari the better for both parties. The German, who will head to Aston Martin next season, starts Sunday’s race 13th in the championship, a staggering 213 points behind Hamilton.
Additional reporting by PA.