Hamilton's championship-leading Ferrari rival Sebastian Vettel, who has a 20-point advantage after nine of 20 races, qualified third.