Updated

Former Spanish Prime Minister Mariano Rajoy vowed loyalty to his Popular Party in an emotional farewell Friday as the conservative party seeks to retake power in Spain.

The 63-year-old politician lost a parliamentary vote last month to his Socialist party opponent, Pedro Sanchez, in the wake of graft convictions for members of his center-right party.

Now in the opposition, Popular Party members on Friday began a two-day congress to choose a new leader between Soraya Saenz de Santamaria, 47, who was deputy prime minister until June, and lawyer Pablo Casado, 37.

The winner faces the challenges of reuniting a party split by a bitter leadership battle and rebuilding its scandal-tarred reputation as rival new parties, both on the left and the right, upend Spain's traditional bi-partisan politics.

Rajoy, who led the party for 14 years, has vowed not to interfere in the election of his successor.

"I'm taking a step aside, but I'm not leaving," Rajoy told a full auditorium, adding: "I will be loyal."

Instead, in an emotional 40-minute televised speech, Rajoy defended his record applying austerity to steer the eurozone's fourth-largest economy out of its worst crisis in decades.

He also said that, despite difficulties, his government had handled well the challenge by Catalan separatists over the northeastern region's sovereignty, which became a full-blown political crisis late last year. He also took pride from "defeating" the militant group ETA, which fought for decades for Basque independence.

In 2017, Rajoy became the first sitting Spanish prime minister to testify as a witness for his party's corruption misdeeds. In a ruling last May, the court fined the party for benefiting from a kickbacks-for-contracts scheme. That prompted the Sanchez-led opposition to call —and win— a vote of no confidence against Rajoy.

Sanchez, Spain's new prime minister, is trying to push ahead with a social agenda that overturns some of his conservative predecessors' policies. That won't be easy however, since he only controls 84 votes in the 350-seat lower house, while the Popular Party has 134 lawmakers.