By Richard Lough

NAIROBI (Reuters) - East Africa's most powerful economy and a key regional ally in the U.S.-led war against militant Islam could next month elect a president accused of crimes against humanity, posing a diplomatic headache for Western capitals.

If Uhuru Kenyatta wins the March 4 poll, Kenya will become the second country after Sudan to have a sitting president facing trial at the International Criminal Court in The Hague.

The son of Kenya's founder president, Kenyatta is running a close second to Prime Minister Raila Odinga in opinion polls.

Foreign powers face a dilemma over what to do if Kenyatta wins the election. His running mate William Ruto is also indicted by the ICC for grave crimes linked to post-election violence following the last poll in 2007.

Several embassies in Nairobi told Reuters it cannot be business as usual when dealing with an ICC indictee.

But they will be reluctant to unravel long-held diplomatic, trade and military ties with one of Africa's more stable democracies and an anchor of stability in a volatile area.

When U.S. President Barack Obama said earlieAnkit0r this month his government supported a vote that "reflects the will of the people", Kenyatta and Ruto trumpeted his words as proof there would be no international blowback should they win.

Washington's top diplomat to Africa was more blunt.

"Choices have consequences," Assistant Secretary Johnnie Carson said, hammering home the same point at least five times during a 40-minute conference call.

Carson did not mention names but the message was clear: there would be implications for Kenya's relations with the world if the Kenyatta-Ruto alliance wins.

"We live in an interconnected world and people should be thoughtful about the impact that their choices have on their nation, on their region, on the economy," Carson said.

If, as many predict, no candidate secures an absolute majority on March 4 and the vote goes to a second round, Kenyatta is expected to be one of the two contenders.

ESSENTIAL CONTACT

Carson intended to sway voters against the ICC indictees, Kenyatta's TNA party said. Any effort, TNA said, to influence voters was not only undemocratic, it denied Kenyans their right to choose freely at the ballot box.

Carson's words lit up the Kenyan social media.

"We don't give a rat's behind (who) says what. Kenya has moved on from hanging on each word from the 'mighty' West," read one comment on the website of Kenya's Daily Nation newspaper.

Another replied: "How can you ignore the US or UK. They are the biggest business dealers with Kenya. It's like saying ignore your wife and she will shut up, but you're married and you have made commitments and you must compromise with each other."

After Carson, Britain, the European Union, France and others turned the diplomatic screws. Their position, they said, was no contact with ICC indictees unless essential.

In response, Kenya's foreign ministry summoned EU envoys, accusing the ambassadors of inflammatory remarks that risked polarizing the country of some 40 million people.

Sources close to the discussion said the meeting was tense. Handshakes were spurned and a joint news conference cancelled.

The vote is the first since President Mwai Kibaki's disputed re-election in 2007 unleashed weeks of fighting between Kenya's main tribes that killed more than 1,200 people. Kenyatta and Ruto backed opposing candidates and are accused of masterminding the unrest.

ICC COOPERATION KEY

Barring any delays, the trial of Kenyatta and Ruto is due to start just days after an anticipated, decisive second round in the Kenyan vote, which would probably pit Kenyatta against Odinga and play out as a referendum on the ICC.

Kenyatta and Ruto both say they intend to comply with their summonses to appear before the court in the Hague and answer charges. But if Kenyatta wins the vote, many Kenyans expect him to refuse to appear, like Sudanese President Omar Hassan al-Bashir, who spurned the court when it charged him with war crimes over the conflict in Sudan's Darfur region.

If a newly-elected Kenyatta were to refuse to appear before the ICC, "you don't need a PhD in international relations to know the options open to us," a Western diplomat said, predicting serious consequences.

Numerous diplomats declined to detail what concrete actions their governments would take in the event an elected Kenyatta shunned the U.N.-backed tribunal. Some simply don't know yet.

A second diplomat cited Sudan as "a perfect example of non-compliance". "(Sudan) gives you an idea of what the maximum response is," the diplomat said.

After scoffing at the ICC, Sudan's Bashir has been targeted by an international arrest warrant. Although the charges against him did not lead directly to economic sanctions against Sudan, the EU's Cotonou agreement governing trade requires compliance with the ICC. Opting out cost Khartoum at least 336 million euros ($452 million) worth of development funds.

Kenya, too, is a signatory of the Cotonou agreement.

Nevertheless, Western countries would be reluctant to punish the Kenyan population. Aid suspensions appear off the agenda.

"We are unlikely to use aid as a political tool," another Nairobi-based diplomat said.

The World Bank and International Monetary Fund would probably continue funding Kenya if Kenyatta wins. Both institutions separate a country's broader economic interests from its leaders.

Even if a newly-elected President Kenyatta does turn up for trial in the Hague, the response would be milder but relations would still become "more complicated" the second diplomat said.

Either way, ambassadors and visiting officials would avoid meeting Kenyatta, although they could work through other government channels.

KENYATTA SUPPORTERS SEE PLOY

Supporters of Kenyatta see the ICC process as a Western ploy to clear Odinga's path to State House.

They say if Kenya's Western allies isolate Kenya they will push the Nairobi government deeper into the arms of another increasingly important trade partner - China.

"It's just common sense. The Chinese aren't attempting to try him in Beijing," a source close to the Kenyatta camp told Reuters. Reuters made several requests to speak to China's embassy in Kenya but was unsuccessful.

Economists and political analysts generally doubt Kenya's traditional partners would seek to impose sanctions aimed at seriously harming the $34 billion economy.

Although a Kenyatta presidency would heighten political uncertainty, it is not seen as a make or break case for foreign investment in Kenya, but there are risks.

Considered the standout economy in east Africa, Kenya has a large private sector that operates relatively independently of government.

"In the next couple of months, investors will be mildly cautious. We would take that as an opportunity to increase positions in Kenya. We're long term investors, we are not traders," said David Mcilroy, chief investment officer of Alquity Investment Management, which runs an Africa equity fund.

Any sign of unease in the market would reflect first in the local currency.

"If in doubt people run to safety. And safety is not in Kenyan shillings," David Cowan, Africa economist at Citi said.

"And in Kenya's case, if you're running a big current account, a big fiscal deficit that needs financing, then that becomes very problematic for you."

A run on the currency would threaten Kenya's below-target hard currency reserves, which the central bank has already begun reducing in the run-up to the poll to support the under-pressure shilling.

Increased uncertainty under Kenyatta's helm could also hamper Kenya's plan to launch a eurobond worth between $750 million and $1 billion in the 2013/14 fiscal year.

"It's not that it's impossible to get the eurobond out, but it means that you pay for more it," one global bank told Reuters, wary of the political sensitivity.

Even so, one economist who declined to be named said the election of an ICC indictee was unlikely to result in a downgrade of Kenya's B+ rating.

"It would be unfortunate but it is kind of what you expect in the 'B' rating category," the economist said.

($1 = 0.7427 euros)

(Additional reporting by James Macharia and Drazen Jorgic in Nairobi and Carolyn Cohn in London; Writing by Richard Lough; Editing by James Macharia and Peter Graff)