WASHINGTON (AFP) - In 2008, just before his 90th birthday, the United States gave Nelson Mandela a special present, striking him from a decades-old terror watch list and ending what US officials called "a rather embarrassing matter."
By then the anti-apartheid icon had long left behind the jail cells where he was incarcerated for 27 years, and was already enjoying retirement and his status as one of the most revered statesmen of the 20th century after becoming South Africa's first black president.
In past years, US officials have beaten a path to his door in his family village hoping some of his almost saint-like aura would rub off on them.
On Thursday, when Mandela died at age 95, President Barack Obama hailed him as belonging "to the ages" and ordered that flags on US government buildings be flown at half-mast - a rare tribute to a foreign leader.
Yet decades ago many in America did not share in the adulation of Mandela and his African National Congress (ANC), which had been billed a terrorist organisation by both South Africa and the United States.
His severest right-wing critics painted him as an unrepentant terrorist and a communist sympathiser.
It was even reported that the CIA had helped engineer Mandela's 1962 arrest when an agent inside the ANC supplied South African security officials with a tip-off to track him down.
In the 1980s however, late Democratic US senator Ted Kennedy drafted legislation with senator Lowell Weicker that would eventually become one of the global catalysts leading to the collapse of the apartheid system.
President Ronald Reagan sought to bury their 1986 anti-apartheid bill aiming to impose economic sanctions on South Africa by imposing his veto, saying he believed it would only lead to more violence and repression for black South Africans.
But for the first and only time that century, Congress rebelled and overrode Reagan's veto on a foreign policy issue, passing legislation that slapped sanctions on Pretoria, snapped direct air links and cut vital aid.
Some observers maintain that the story of Mandela's redemption and the undeniable justness of his cause hold unique lessons for Washington as it grapples with other flagrant abuses of human rights by repressive regimes around the world.
Brian Dooley, who worked with Kennedy on the game-changing legislation and is now a director with Human Rights First, chafes at the rationale that the US pursues "constructive engagement" with autocratic regimes for the greater good and to ensure security interests.
"The justifications for propping up the apartheid regime are now almost the same as we hear when we talk about why isn't the US more robust in taking on human rights violations in Saudi Arabia or Bahrain or various other parts of the world," Dooley said.
"Forget the morality if you like for a second, and look at just the national interest, the self-interest. Standing with the bad guys not only looks bad - it is bad. And eventually they fall, and eventually there is dreadful resentment."
The lessons of the apartheid era are still applicable today, Dooley says, as "only the fact that Congress overrode the veto saved the US reputation."
Until five years ago, Mandela and other members of the ANC remained on the US terror watch list because of their armed struggle against the apartheid regime, which yielded to majority rule in the mid-1990s.
The designation meant that the US State Department had to issue them with a waiver to enter the country for meetings such as the UN General Assembly, something former secretary of state Condoleezza Rice said she found "embarrassing."
When Mandela was finally removed from the list in 2008, then senator and current Secretary of State John Kerry, said: "He had no place on our government's terror watch list, and I'm pleased to see this bill finally become law."
In a televised address from the White House on Thursday, Obama said Mandela was "a man who took history in his hands and bent the arc of the moral universe towards justice."
"A free South Africa, at peace with itself, that's an example to the world, and that's Madiba's legacy to the nation that he loved," Obama said, referring to Mandela by his clan name.
J. Peter Pham, director of the Africa Center at the Atlantic Council, called Mandela "one of the rare international statesmen that captured the imagination of Americans across the political spectrum."
"Even those who are not normally interested in Africa found him a very compelling individual," said Pham, who was awarded the 2008 Nelson Mandela International Prize for African Security and Development.