The country's first black president was admitted to a Pretoria hospital on December 8 after being flown from his home village of Qunu in a remote part of the Eastern Cape province.

He was treated initially for a recurrent lung infection and then had a successful procedure to have gallstones removed.

Mandela, who came to power in historic elections in 1994 after decades struggling against apartheid, remains a symbol of resistance to racism and injustice at home and around the world.

Presidency spokesman Mac Maharaj said he had visited Mandela on Tuesday. "He is looking much better," he said in a statement, adding that the Nobel Peace laureate had spoken to him.

Doctors were satisfied with his progress, Maharaj said.

"They say there is no crisis, but add that they are in no hurry to send him home just yet."

Maharaj said that, given his advanced age, Mandela needed "extraordinary care". "If he spends more days in hospital, it is because that necessary care is being provided," he added.

He said Mandela would remain in hospital until doctors were "satisfied that he has made sufficient progress".

Reporting their conversation, Maharaj said Mandela asked him: "'Mac, what are you doing here?"

"I asked him not to give doctors any trouble," he added.

Mandela spent 27 years in apartheid prisons, including 18 years on the windswept Robben Island off Cape Town.

He was released in 1990 and went on to use his prestige to push for reconciliation between whites and blacks as the bedrock of the post-apartheid "Rainbow Nation".

He stepped down in 1999 after one term in office and has been largely removed from public life for the last decade.

Mandela spent time in a Johannesburg hospital in 2011 with a respiratory condition, and again in February this year because of abdominal pains. He was released the following day after a keyhole examination showed there was nothing serious.

He has since spent most of his time in Qunu.

His fragile health prevents him from making any public appearances in South Africa, although he has continued to receive high-profile domestic and international visitors, including former U.S. president Bill Clinton in July.