Ahead of , Alonso extended his contract with Ferrari until . His main competition for the title in 2012 was Vettel. Wins in Malaysia, Valencia and Germany and consistent points-scoring finishes allowed him to build a 40-point lead in the Drivers' Championship. Thereafter start-line collisions, a mechanical failure and an improved performance for Vettel eliminated Alonso's points lead. Alonso entered the season-ending 13 points behind Vettel and needed to finish third and for Vettel not to score points for a third championship. He was second and Vettel finished fourth to be runner-up for the second time in his career on 278 points.