(Adds comment from Del Mazo, PRI voter)
TEXCOCO, Mexico June 4 (Reuters) - Pig heads dumped outside polling stations and phone threats marred the final hours before an election in a major Mexican state where voters decide on Sunday whether to stick with the ruling party, in a dry run for next year's presidential contest.
President Enrique Pena Nieto's Institutional Revolutionary Party, or PRI, is battling to halt a run of losses. It is squaring off in the State of Mexico, its biggest regional bastion, with the new party of leftist Andres Manuel Lopez Obrador, who leads early opinion polls for the July 2018 presidential race.
In PRI hands since 1929, the State of Mexico is home to one in eight Mexican voters. If it falls to Lopez Obrador's National Regeneration Movement, or MORENA, it could provide him with a springboard to the top job.
"It's a pivotal election, not just for MORENA, it's a pivotal election for Mexico," the two-time presidential runner-up said in a recent radio interview. "Imagine the message that will go out to the world (if MORENA wins)."
Victory for the combative Lopez Obrador in 2018 could push Mexico in a more nationalist direction at a time of heightened tensions with the United States. U.S. President Donald Trump has riled Mexicans with threats to tear up the North American Free Trade Agreement and build a border wall to keep out illegal immigrants.
Prosecutors are investigating piles of pig heads left on Saturday in several municipalities in the state that curves round Mexico City, as well as telephone threats and fake electoral literature warning of attacks.
The threats were intended to dissuade people from voting, the special prosecutor for electoral crimes said in a statement. Mexican media showed images of the pig heads outside MORENA offices, as well as polling stations.
Other images showed funeral wreaths placed at the homes of local electoral officials. It was not clear who was behind the threats.
Mariel Vazquez, 42, a small businessman from Texcoco, at the polling station on the outskirts of Mexico City where MORENA candidate Delfina Gomez was voting, said what he called "dirty work, tricks" meant his favored candidate might not win.
"(But) if I don't come to vote or if I vote blank, that vote goes to the PRI," Vazquez said, declining to say which candidate he voted for. "I don't want more of the PRI."
The PRI's standard-bearer for governor, Alfredo del Mazo, oted at a polling station surrounded by his family in the state capital, Toluca, where he expressed hope the day would be "a celebration of democracy."
"This should be a day in which all votes are respected, in which the institutions conducting the election are respected," he said.
Accusations of vote-buying and intimidation are common in Mexican elections, especially at the state and local levels. The tight race in the State of Mexico has made the stakes higher for the parties.
Opinion polls show MORENA's Gomez running neck and neck with PRI rival del Mazo in the region of 16 million people that Pena Nieto himself once governed. Del Mazo is a distant cousin of the president and the son and grandson of former state governors.
Pena Nieto's popularity helped his successor retain the state by a landslide in 2011, but his 4-1/2 years as president have battered his reputation and hurt the party.
Failing to end corruption scandals that have long tarnished the PRI, and struggling to tame brutal gang violence, the president is no longer an electoral asset, while his home state has become a symbol of all that plagues his administration.
Polls show most voters in the State of Mexico want a new government but are divided about who should form it.
The PRI also defends two other governorships on Sunday, in the states of Nayarit and Coahuila. Polls show the PRI is trailing well behind the main opposition candidate in Nayarit, and is in a tight race in Coahuila, where it could be ousted for the first time. In the violent state of Veracruz, voters choose new municipal authorities on Sunday.
Under Pena Nieto, the party's once iron hold on Mexico's states has gradually weakened, and it now has five fewer governors than when he took office. Going into Sunday, the PRI and its allies controlled 16 states, or half the regional governments.
The State of Mexico is the jewel in the PRI's fading crown, and the party is not giving it up without a fight.
Opposition accusations of PRI vote-buying are rife.
"They're doing what they did in 2011, but on a bigger scale and in greater volume," said Alejandro Encinas, a leftist opposition senator who finished second in the 2011 contest for the state.
"The penetration of money is quite something where there's so much poverty. You have whole families who sell their vote."
The PRI rejects the accusations, and some of its voters heaped scorn on Lopez Obrador.
"That man is crazy with power. Just look at the government of (Venezuelan President Nicolas) Maduro. Andres Manuel has the same political ideology as him and just look at what's happening there," said Brenda Hernandez, a 32-year-old teacher who said she voted for del Mazo.
Polls close at 6 p.m. (2300 GMT). (Additional reporting by Dave Graham, Anahi Rama, David Alire Garcia and Noe Torres; Editing by Andrea Ricci and Peter Cooney)