Mariano Rajoy, whose conservative Popular Party (PP) has ruled since 2011, lost a first confidence vote on Wednesday with 170 in favour - six votes short of the required absolute majority.
This time around he only needs more votes in favour than against but he is expected to fail again since the parties that opposed him have said they will maintain their "no" votes rather than abstaining to allow him to form a minority government.
The PP, in power since 2011, won the most seats in elections held in December and June but fell short of a majority both times as voters angry over corruption and austerity flocked to new parties.
It has only managed to secure the support of new centrist party Ciudadanos and a lone MP from the Canary Islands.
If there is no breakthrough two months after Wednesday's parliamentary ballot, vote-weary Spaniards will be asked to return to the polls in December.
The PP has pressured the Socialists, their main rivals who finished second in the last two elections, to drop their opposition.
"We can't have new elections, we can't be this ridiculous," said the PP's parliamentary spokesman, Rafael Hernando, ahead of the second vote in the assembly expected late Friday.
Rajoy argued during Wednesday's debate that he deserved to be prime minister again because his party had won 2.5 million more votes than the Socialists in the June 26 election and was the only formation to boost its showing.
But Socialist leader Pedro Sanchez told MPs that Rajoy had "no credibility" because of allegations of illegal financing that have dogged the PP under his watch.
Sanchez fears losing his own credibility with his supporters if he were to abandon his long-time opposition to Rajoy, according to members of his entourage.
"We are going to do what we said we would do during the election campaign, which is to not allow Rajoy to remain at the head of the government," the Socialists' parliamentary spokesman Antonio Hernando said Thursday.
The New York Times also urged the Socialists to abstain in an editorial published Friday, arguing "there is little chance they would improve their position in December."
"The alternative, however, is four more months of interim government, which means no budgets, no new ministers and most likely no legislation," it added.
Although Rajoy remains in office as acting prime minister, he has no power to propose legislation or spend on new infrastructure projects such as roads and railways.
The lack of a fully-functioning government has also delayed the drafting of a 2017 budget, which needs to be approved by mid-October to comply with European Union rules.
One factor that could change the political calculus is the result of regional elections in the Basque Country on September 25th.
The Basque Nationalist Party (PNV), which has five seats, could support Rajoy nationally if it needs the backing of the PP to govern in the Basque Country following the regional polls.
The PNV has backed minority PP governments in the past but Rajoy has angered the party with his strong defence of national unity over the years.
By Patrick Rahir