Ferrari secured a shock front row lockout with Leclerc and Carlos Sainz at the Autodromo Hermanos Rodriguez as Max Verstappen, who had topped all three practice sessions, ended the decisive Q3 session third fastest for Red Bull.
The final classification was subject to a number of post-qualifying investigations, with Verstappen and George Russell plus his Mercedes team-mate Lewis Hamilton among those summoned to face the stewards for pitlane impeding and a yellow flag infringement respectively.
But all drivers escaped sanctions, and will line up as they ended qualifying,.
Daniel Ricciardo and Alex Albon were among those who had threatened to break out of the midfield during practice. But while the AlphaTauri driver was able to translate this potential into a top-four qualifying position, prompting him to declare that he feels "a lot like my old self", a frustrated Albon dropped out of the running in Q2 following a track limits violation.
Meanwhile it was another disappointing afternoon for Aston Martin following its US Grand Prix nadir. Fernando Alonso was only 13th after being knocked out in Q2, while Lance Stroll failed to progress from Q1 and was 18th.
Lando Norris is another driver who will have his work cut out on Sunday, after the McLaren driver qualified 19th. The Briton took full blame for not getting the most from his tyres after being called to abort his opening run, but will at least start ahead of Logan Sargeant who failed to set a time in qualifying due to track limits infringements.
The 19th round of the 2023 F1 season, the Mexico GP at the Autodromo Hermanos Rodriguez, gets under way at 2:00pm local time (8:00pm GMT) on Sunday 29 October.
Source: Autosport