* ANC to vote to replace Zuma as party chief
* Winner likely to emerge as next S.African president
* Party once led by Mandela now split, tainted by graft
* Reviving struggling economy a key election issue (Adds Zuma speech)
By Alexander Winning and Nqobile Dludla
JOHANNESBURG, Dec 16 (Reuters) - South Africa's Jacob Zuma gave his last speech as African National Congress head on Saturday, as the only party in power since the end of apartheid prepared to pick its next leader, and likely future president, in a vote that was too close to call.
The election is perhaps the most pivotal moment for the ANC in its 23 years of power. Scandal and corruption allegations have tainted Zuma's presidency and the party that launched black majority rule under Nobel Peace Prize laureate Nelson Mandela is now deeply divided, its image tarnished at home and abroad.
The race to succeed the 75-year-old as ANC leader has been dominated by Deputy President Cyril Ramaphosa, 65, generally favoured by financial markets, and Nkosazana Dlamini-Zuma, 68, an ex-cabinet minister, chairwoman of the African Union Commission and Zuma's ex-wife.
Zuma, who is backing Dlamini-Zuma in the race, can remain head of state until 2019.
The ANC will announce Zuma's successor on Sunday, concluding a bruising leadership battle that threatens to splinter the 105-year-old liberation movement.
A trained lawyer and former union leader, Ramaphosa, 65, has vowed to fight corruption and revitalise an economy that has slowed to a near-standstill under Zuma with 28 percent unemployment and credit rating downgrades.
That message has played well with foreign investors and Ramaphosa is expected to be backed by ANC veterans, labour unions and civil society organisations.
In contrast, Dlamini-Zuma is seen as a fierce campaigner against racial inequality whose hostility to big business has rattled investors.
"She has not made corruption the only pillar of her campaign, because the most critical issue in South Africa is this huge inequality," said Carl Niehaus, a key member of Dlamini-Zuma's campaign.
Colin Coleman, managing director of Goldman Sachs in South Africa, said the candidates' distinct positions on the economy made the choice between them a clear one.
"This is a pivotal moment. It is a choice between refreshing the ANC and putting South Africa on a course of a modern economy, or the party outlook may move deeper down a patronage path which would lead to a low-growth and high-unemployment outcome for the people of South Africa."
In a boost to Ramaphosa, courts ruled that some senior officials from provinces seen as supporting Dlamini-Zuma had been elected illegally and were barred from the conference. The rand currency firmed more than 2 percent after that news on Friday.
The ANC's National Executive Committee, a decision-making group of senior leaders, met before the conference began and decided that barred delegates could not vote at the conference.
ANC Youth League leader Collen Maine, who backs Dlamini-Zuma, said that meant 122 delegates - out of about 6,000 - would be prevented from voting , something he called "not significant".
Asked if barring the delegates helped Ramaphosa, a senior official of Cosatu, South Africa's largest union federation, said: "Definitely. But we are not banking only on that. We have trust that ANC delegates know what the country needs at the moment."
John Ashbourne, Africa economist at Capital Economics, said: "Early signs of a win for Cyril Ramaphosa, the more investor-friendly option, have provided support for the rand.
"But while Mr. Ramaphosa is popular among party members, the result will be decided by political insiders, who may opt for his leftist opponent, Nkosazana Dlamini-Zuma."
Zuma cracked jokes, sang and danced after reading his last speech as ANC leader.
Zuma warned members not to run to the courts to resolve party problems. He did not specifically mention the barring of delegates at the conference by the courts this week.
"Factionalism has become the biggest threat to the organisation," he said.
The president also said allegations against businessmen accused of wielding undue influence over his government would be investigated. The High Court ruled on Wednesday that Zuma must set up a judicial inquiry into state influence-peddling within 30 days.
Zuma announced plans to raise subsidies to universities to 1 percent of GDP over the next five years from nearly 0.7 percent at present, a move analysts said was timed to appeal to the more populist members of the party. (Additional reporting by James Macharia, Olivia Kumwenda-Mtambo and Ed Stoddard; Writing by James Macharia; Editing by Robin Pomeroy)
Our Standards: The Thomson Reuters Trust Principles.