HAVANA - Cuba's historic revolutionary leader Fidel Castro died Friday aged 90, after defying the United States during a half-century of iron-fisted rule and surviving the eclipse of global communism.

One of the world's longest-serving rulers and modern history's most singular characters, Castro defied 11 US administrations and hundreds of assassination attempts.

His younger brother, President Raul Castro, announced the news shortly after midnight (0500 GMT Saturday) but gave no details of the cause of death.

Fidel Castro crushed opposition at home from the moment he took power in 1959 to lead the communist Caribbean island through the Cold War. He stepped aside only in 2006 after intestinal surgery.

For defenders of the revolution, Castro was a hero who protected the ordinary people against capitalist domination.

For his opponents, including thousands of Cuban exiles living in the United States, he was a cruel tyrant.

Castro eventually lived to see the restoration of diplomatic ties with Washington last year.

President Raul Castro, who took power after his elder brother Fidel was hospitalised in 2006, announced the news on national television just after midnight Friday (0500 GMT Saturday).

"The commander in chief of the Cuban revolution died at 22:29 hours this evening," Raul Castro said in a solemn voice.

"In compliance with Comrade Fidel's expressed will, his remains will be cremated early in the morning" on Saturday.

The government on Saturday decreed nine days of mourning.

From November 26 to December 4, "public activities and shows will cease, the national flag will fly at half-mast on public buildings and military installations," a statement from the state executive said.

Castro's ashes will be buried in the southeastern city of Santiago on December 4 after a four-day procession through the country, it added.

Castro's death drew strong reactions from world leaders.

"The name of this distinguished statesman is rightly considered the symbol of an era in modern world history," said Russian President Vladimir Putin in a telegram to Raul Castro.

Former Soviet leader Mikhail Gorbachev said the late leader left a "deep mark in the history of mankind."

"Comrade Castro will live forever," said Chinese President Xi Jinping in a message read on television. "Castro was "a great man of our time... History and people will remember him."

French President Francois Hollande said Castro "represented, for Cubans, pride in rejecting external domination."

Venezuelan President Nicolas Maduro, Cuba's main ally in the region, said on Twitter: "It is up to us to continue his legacy and carry his flag of independence."

JOY IN MIAMI, GRIEF IN HAVANA

In the streets of Miami, home to the bulk of the US Cuban community, euphoric crowds waved flags and danced, banging on pots and drums and honking their car horns.

"It's sad that one finds joy in the death of a person - but that person should never have been born," said Pablo Arencibia, 67, a teacher who fled Cuba 20 years ago.

"Satan is now the one who has to worry," he added, because "Fidel is heading there and is going to try to get his job."

Castro was loathed by many for stifling dissent, but loved by others for providing free universal healthcare and education.

"Losing Fidel is like losing a father - the guide, the beacon of this revolution," said Michel Rodriguez, a 42-year-old baker in Havana.

Fidel Castro came to power in 1959 as a black-bearded, cigar-chomping 32-year-old, in a revolution against former dictator Fulgencio Batista.

"When this war is over, a much longer greater war will begin: the war that I am going to wage against them," the United States, he had said in 1958. "I realize that will be my true destiny."

Living by the slogan "socialism or death," Castro kept the faith to the end, even as the Cold War came and went.

He endured more than 600 assassination attempts, according to his aides, and the disastrous US-backed Bay of Pigs invasion attempt in 1961. "If I am considered a myth, the United States deserves the credit," he said in 1988.

Castro was at the center of the Cuban Missile Crisis in 1962, as the world stood on the brink of nuclear war.

Eventually the Soviet Union backed down in its bid to station strategic missiles on Cuban soil.

Born August 13, 1926 to a prosperous Spanish immigrant landowner and a Cuban mother of humble background, Castro was a quick learner and a keen baseball player.

His political path was set when he formed a guerrilla opposition to the US-backed government of Batista, who had seized power in a 1952 coup.

In 1953 Castro led a small rebel force that attacked a major military base, the Moncada Barracks in Santiago, in a bid to oust Batista. The drive failed. Castro was put on trial, and in a self-defense speech said he did not care if was convicted.

"History will absolve me," he famously said.

After two years of prison Castro went into exile in Mexico and organized followers for their ultimately triumphant uprising.

On December 2, 1956 the rebels sailed to southeastern Cuba on the ship Granma. Twenty-five months later, they ousted Batista and Castro was named prime minister.

Castro threw Cuba's lot in with the Soviet Union, which bankrolled his regime until 1989, when the Eastern Bloc's collapse sent Cuba's economy plunging.

Fidel ceded power to his younger brother Raul, now 85, in July 2006. The revolutionary icon underwent intestinal surgery and disappeared from public view.

Castro married three times and is known to have fathered eight children.

In his most recent photographs, published last week, Castro appears in the white tracksuit that he has worn since leaving power.

He was last seen in public on his 90th birthday on August 13.

"Soon I will end up like everyone does," Castro said recently. "We all have our turn."