Sanchez takes reins of power after People's Party leader Mariano Rajoy was forced out in a vote of no-confidence.

Pedro Sanchez was sworn in as Spain's Prime Minister on Sunday, a day after the Socialist party (PSOE) leader successfully ousted predecessor Mariano Rajoy who lost a no-confidence vote in parliament.

Rajoy attended the swearing in ceremony, which was held in the Palace of Zarzuela in Madrid. Rajoy shook Sanchez's hand after the new leader was sworn in by King Felipe VI.

The two then posed for a photo with the monarch along with the speakers of the lower Congress of Deputies and the Senate.

Mr Sanchez toppled Rajoy following a court ruling in a major corruption case involving the conservative leader's Popular Party.

Parliament voted 180-169 on Friday to replace Rajoy's government with one led by Mr Sanchez. One politician abstained.

Spain is in the eurozone's top four economies and is an influential member of the European Union.

Sanchez and his party are staunch supporters of the EU and the shared currency.

Mr Sanchez has vowed to fight corruption and help those Spaniards affected by years of public spending cuts under Mr Rajoy's government.

He also pledged to hold an election soon although did not set a date.

Mr Sanchez will lead a minority government and will need the support of both the far-left Podemos (We Can) party and the backing of a motley crew of regional parties and Catalan secessionists to get anything done in government.

The 46-year-old Mr Sanchez is Spain's seventh prime minister since the return to democracy following the death of dictator General Francisco Franco in 1975.

His majority is also the smallest for a Spanish government since the return to democracy, making it unclear how long his administration can last.