(Adds context, background, comments)
By Zach Dyer
SAN JOSE, March 5 (Reuters) - Costa Rica's ruling party candidate Johnny Araya on Wednesday abandoned his presidential campaign a month before a runoff, a move that appeared to guarantee victory for leftist former diplomat Luis Guillermo Solis.
Araya, of the ruling centrist National Liberation Party (PLN), said he would no longer campaign, though under the constitution his name will remain on the ballot. He said he had made the decision after polls showed him way behind Solis.
A favorite to win before the first round of voting in February, Araya has been beset by voter resentment over government corruption scandals under President Laura Chinchilla and rising inequality. Solis scored a surprise win in that vote, and has stretched his lead dramatically in opinion polls.
"There is an increasing will to replace the party in government," Araya told a news conference, declining to take questions. "I will abstain from any electoral activity."
A former mayor of San Jose, Araya, 56, has faced criticism from equality-conscious voters for gaffes like underestimating the price of milk in an interview.
The national prosecutor's probe of allegations of abuse of power and embezzlement also dampened his appeal after Chinchilla sparked outrage by accepting flights on a private jet despite laws barring public officials from accepting sizable gifts.
"The PLN needs to really think hard about the corruption issue," said political anlayst Francisco Barahona.
A defeat for Araya's PLN would remove the party from power after two consecutive terms, or eight years, in office.
Henry Mora, an incoming lawmaker in Solis' Citizens' Action Party (PAC), told Reuters the unpopularity of the governing party meant his candidate was almost guaranteed to prevail.
"Everything was set for a beating (for the PLN)," he said.
A University of Costa Rica survey published late on Tuesday showed Araya trailed Solis 20.9 percent to 64.4 percent ahead of the April 6 runoff.
The lead marks a dramatic upswing for Solis, who won 30.64 percent of the ballot last month to 29.71 percent for Araya. Neither candidate reached the minimum 40 percent plus one vote threshold needed to avoid a second-round runoff.
However, Solis faces a challenge passing legislation even if his massive lead holds in the run-up to the final vote.
Results for the National Assembly elections last month showed the PLN would have the most seats in the legislature, with all parties well short of an outright majority.
Costa Rica's Chamber of Industry said in a statement it was surprised at the news but that Araya's withdrawal had at least generated a degree of certainty for businesses.
Araya's move marked the first time a presidential hopeful had quit at this stage under the current electoral system. In 1932, former Foreign Minister Manuel Castro dropped out of the race before a runoff after taking part in a failed rebellion. (Reporting by Alexandra Alper and Zach Dyer; Editing by Simon Gardner, Chizu Nomiyama and Jonathan Oatis)