Rosberg had been the faster of the Mercedes pair early in the session while on the slower soft-compound Pirellis, outpacing Hamilton by just over three tenths of a second.
But the world championship leader made a mistake at Turn 2 on his first flying lap on super-soft rubber, meaning he was unable to improve his time until his next lap.
Hamilton then put in a 1m18.341s on his first flier, setting the fastest time in the middle sector, with Rosberg ending up 24 thousandths of a second slower.
Mercedes later had a problem in the pits when Hamilton came in unexpectedly and the team had Rosberg's tyres ready, meaning that it took time to get his correct tyres.
With Hamilton sat in the pits, Rosberg came in and had to queue to wait for the team to put on the correct tyres amid concerns about his brakes overheating.
Daniel Ricciardo was third fastest for Red Bull, just a tenth off the pace, with Ferrari driver Kimi Raikkonen a strong fourth, half a second down.
Kevin Magnussen continued his recent run of impressive form with fifth fastest, just ahead of Williams driver Felipe Massa, who was briefly second fastest in the early stages of the super-soft runs.
Sauber driver Adrian Sutil was 11th fastest for Sauber ahead of Daniil Kvyat, with Force India pairing failing to break the top 10 for the second grand prix Friday in a row in 13th and 14th place.
Caterham had a troubled session, with both cars stopping on the circuit.
Kamui Kobayashi parked with flames emerging from the rear of the car after completing 12 laps, while Marcus Ericsson was ordered to stop his car on track because of a drop in oil pressure after just three laps.
But the team did get Ericsson's car back and he was able to return to the track in the final half hour, allowing him to set the 20th fastest time.
With the ambient temperature at over 30C throughout the afternoon, track temperatures hit 58C, the highest so far this season.
- Motor Racing
- Sports & Recreation