Cuba's former leader Fidel Castro was a "brutal dictator", US President-elect Donald Trump has said, hours after the 90-year-old's death was announced.
Mr Trump, who takes office in January, said he hoped Cubans could move towards a freer future.
Castro came to power in 1959 and ushered in a Communist revolution. He defied the US for decades, surviving many assassination plots.
Supporters said he returned Cuba to the people. Critics called him a dictator.
His brother Raul, who succeeded him as president, announced his death on state television on Friday night.
"While Cuba remains a totalitarian island, it is my hope that today marks a move away from the horrors endured for too long, and toward a future in which the wonderful Cuban people finally live in the freedom they so richly deserve," Mr Trump said in a statement.
Under Barack Obama, the US-Cuba relationship warmed and diplomatic ties were restored in 2015 after decades of tension.
Mr Trump roundly criticised the policy on the campaign trail but made no mention of his pledge to reverse it in his statement, saying his administration would do all it could to ensure Cubans could "begin their journey toward prosperity and liberty".
Mr Obama, meanwhile, said history would "record and judge the enormous impact" of Castro. America was extending "a hand of friendship to the Cuban people" at this time, he added.
Castro was the longest serving non-royal leader of the 20th Century. He had been retired from political life for several years, after handing power to his brother in 2006 because of illness.
He will be cremated later on Saturday and a period of official mourning has been declared on the island until 4 December, when his ashes will be laid to rest in the south-eastern city of Santiago.
News of his death left some in Havana stunned. "I always said it couldn't be," said one woman, a government employee. "Even though they said it now, I say it can't be."
But Cuban dissident group Ladies in White, which was founded by wives of jailed dissidents, tweeted: "May God forgive him, I won't".
In Miami, where there is a large Cuban community, there have been celebrations in some parts of the city, with people banging pots and cheering.
How he defied the US
Throughout the Cold War, Fidel Castro was a thorn in Washington's side.
An accomplished tactician on the battlefield, he and his small army of guerrillas overthrew the military leader Fulgencio Batista in 1959 to widespread popular support.
Within two years of taking power, he declared the revolution to be Marxist-Leninist in nature and allied the island nation firmly to the Soviet Union.
Despite the constant threat of a US invasion as well as the long-standing economic embargo on the island, Castro managed to maintain a communist revolution in a nation just 90 miles (145km) off the coast of Florida.
Despised by his critics as much as he was revered by his followers, he maintained his rule through 10 US presidents and survived scores of attempts on his life by the CIA.
He established a one-party state, with hundreds of supporters of the Batista government executed. Political opponents have been imprisoned, the independent media suppressed. Thousands of Cubans have fled into exile.
How has the world reacted?
Many world leaders have paid tribute to Castro. Russian President Vladimir Putin described him as a "reliable and sincere friend" of Russia, while Chinese President Xi Jinping said his people had "lost a good and true comrade".
The Soviet Union's last leader, Mikhail Gorbachev, said: "Fidel stood up and strengthened his country during the harshest American blockade, when there was colossal pressure on him."
UN Secretary General Ban Ki-moon acknowledged advances in education, literary and health under Castro, but said he hoped Cuba would "continue to advance on a path of reform, greater prosperity and human rights".
Pope Francis, who met Castro, an atheist, when he visited Cuba in 2015, called his death "sad news".
In Venezuela, Cuba's main regional ally, President Nicolas Maduro said "revolutionaries of the world must follow his legacy".
Fidel Castro's key dates
- 1926: Born in the south-eastern Oriente Province of Cuba
- 1953: Imprisoned after leading an unsuccessful rising against Batista's regime
- 1955: Released from prison under an amnesty deal
- 1956: With Che Guevara, begins a guerrilla war against the government
- 1959: Defeats Batista, sworn in as prime minister of Cuba
- 1961: Fights off CIA-sponsored Bay of Pigs invasion by Cuban exiles
- 1962: Sparks Cuban missile crisis by agreeing that USSR can deploy nuclear missiles in Cuba
- 1976: Elected president by Cuba's National Assembly
- 1992: Reaches an agreement with US over Cuban refugees
- 2006: Hands over reins to brother Raul due to health issues, stands down as president two years later