Leclerc's team-mate Carlos Sainz had led the final morning session from Red Bull's Sergio Perez before running was interrupted by a broken drain cover for the second day in a row.
Because repairs halted the test for 1h17, the decision was taken to cancel the planned one-hour lunch break and carry on all the way to the chequered flag at 7pm local time.
There was early trouble for McLaren, which added to its testing gremlins this week with an apparent clutch issue for Lando Norris. Sauber's Valtteri Bottas also ran a restricted programme while his team worked on the floor and rear end of his green and black car.
In the afternoon, Max Verstappen took over from Perez in the RB20, while Leclerc replaced Sainz in the scarlet Ferrari.
Leclerc soon went third fastest behind Sainz and Perez until Verstappen put down a 1m31.058s, followed by a 1m30.763s on used C3 tyres 25 minutes later.
Leclerc replied with a 1m30.409s, but used the C4 compound which is a significant step softer and won't be used at next week's Bahrain Grand Prix at the same Sakhir circuit.
With two hours left to run the Monegasque driver took on another set of the red side-walled tyre to clock a 1m30.322s, going four tenths clear of the world champion.
Heading towards the final hour most heavy hitters switched their focus to longer runs on the hardest tyres.
But RB's Yuki Tsunoda used C4s to vault up to third in the final hour, half a second shy of Leclerc.
He was soon shadowed by George Russell, who was fourth 0.040s behind on the harder C3 tyre, while Alex Albon lifted himself to fifth with a late C4 lap.
Albon was the only driver to stay in the car all day, completing 121 laps aboard the Williams FW46.
Bolting on the C4s himself, Russell then attacked Leclerc's table-topping time but a purple third sector wasn't enough to dislodge the Ferrari as the Briton finished second, 0.046s behind.
Sauber driver Zhou Guanyu followed Russell through in third with a 1m30.647s, which demoted Verstappen to fourth.
Behind Tsunoda and Albon, McLaren's Oscar Piastri and Aston Martin's Fernando Alonso had moved up right before sunset to end the test seventh and eighth respectively.
Sainz's morning time held up for ninth ahead of Perez and Haas man Nico Hulkenberg.
Lewis Hamilton finished off his winter test in 12th after running 49 laps in the morning. He was followed by morning runners Lance Stroll (Aston Martin) and Norris.
Pierre Gasly and Esteban Ocon completed a low-key test for Alpine in 15th and 17th respectively, split by Haas' Kevin Magnussen.
After his limited morning running Bottas was 18th, with RB's Daniel Ricciardo the slowest of the 19 active drivers on Friday.
The 2024 season kicks off in earnest on Thursday with first practice for the Bahrain Grand Prix, which this year will be held on a Saturday.
Pos | Driver | Team | Time | Gap | Laps | Tyres |
1 | Charles Leclerc | Ferrari | 1:30.322 | 74 | C4 | |
2 | George Russell | Mercedes | 1:30.368 | +0.046s | 67 | C4 |
3 | Zhou Guanyu | Sauber | 1:30.647 | +0.325s | 85 | C4 |
4 | Max Verstappen | Red Bull Racing | 1:30.755 | +0.433s | 66 | C3 |
5 | Yuki Tsunoda | RB | 1:30.775 | +0.453s | 53 | C4 |
6 | Alexander Albon | Williams | 1:30.984 | +0.662s | 121 | C4 |
7 | Oscar Piastri | Mclaren | 1:31.030 | +0.708s | 91 | C3 |
8 | Fernando Alonso | Aston Martin | 1:31.159 | +0.837s | 75 | C3 |
9 | Carlos Sainz | Ferrari | 1:31.247 | +0.925s | 71 | C3 |
10 | Sergio Perez | Red Bull Racing | 1:31.483 | +1.161s | 53 | C3 |
11 | Nico Hulkenberg | Haas | 1:31.686 | +1.364s | 89 | C3 |
12 | Lewis Hamilton | Mercedes | 1:31.999 | +1.677s | 49 | C5 |
13 | Lance Stroll | Aston Martin | 1:32.038 | +1.716s | 46 | C3 |
14 | Lando Norris | Mclaren | 1:32.108 | +1.786s | 20 | C3 |
15 | Pierre Gasly | Alpine | 1:32.149 | +1.827s | 47 | C3 |
16 | Kevin Magnussen | Haas | 1:33.053 | +2.731s | 80 | C3 |
17 | Esteban Ocon | Alpine | 1:33.079 | +2.757s | 55 | C3 |
18 | Valtteri Bottas | Sauber | 1:33.528 | +3.206s | 28 | C3 |
19 | Daniel Ricciardo | RB | 1:37.015 | +6.693s | 70 | C1 |