A lawyer who became a Marxist guerrilla, Fidel Castro survived numerous assassination plots by US intelligence services including one extraordinary plan to poison his cigar.
Castro - rarely seen in public without his trademark military fatigues and cap - was famous for long rambling speeches filled with historical references.
But despite the fact these speeches would often drag on for hours, thousands would turn out to hear their leader.
Born in Biran, Cuba, into a wealthy farming family, he was educated at Jesuit schools before studying law at the University of Havana.
After working as a lawyer for three years, he planned to stand for Parliament in 1952, but the Government was overthrown in a coup staged by General Fulgenco Batista.
Castro accused the US-backed Batista of violating the constitution and led an attack on his Moncada Barracks in the Oriente province.
He was taken prisoner and jailed for 15 years, but was released in a general amnesty in 1955 before going into exile in Mexico and the US.
He later returned to Cuba with just 12 men, including Argentinian-born revolutionary Ernesto "Che" Guevara, and fought a guerrilla battle against Batista's forces before eventually toppling him in 1959.
Within months he had embraced the former Soviet Union and fallen out with the US, seizing American-owned property and companies in Cuba.
The outcome was the Bay of Pigs invasion when Cuban exiles backed by the CIA attempted to overthrow Castro.
The US, however, completely misread the mood of the Cuban people who rather than turning their backs on Castro rose up in support of their leader and massacred the invaders.
Cuban-American relations were to reach crisis level a year later when US spy satellites discovered the groundwork for a long-range Soviet missile base on Cuba.
President John Kennedy ordered a naval blockade of Cuba, precipitating an American-Soviet nuclear stand-off.
For days the world held its breath before Soviet President Nikita Khrushchev backed down and ordered missile-laden ships back to port.
From then on the US regarded Cuba with nothing but suspicion and contempt.
Domestic policies and foreign embargoes steadily crippled the Cuban economy but Castro remained untouchable - although increasingly dependent on Soviet support.
Carefully staged public rallies presented an image to the outside world of an adored president.
But a different set of pictures told another story, as cameras filmed Cubans packed onto makeshift rafts fleeing to the US.
Opposition to his rule centred in areas of the US like Miami. However, Castro's position was boosted by a high-profile visit by Pope John Paul II in 1998.
In July 2006 it was announced that he had undergone stomach surgery and put his brother Raul - a fellow revolutionary from the 1950s - in charge of the country.
He formally resigned as president in February 2008.
Castro was a serial womaniser and is thought to have had at least nine children.
But only one, Fidelito, a nuclear scientist, by his first wife Mirta Diaz-Balart, has been officially recognised.
He had another five sons with Dalia Soto del Valle, a former teacher he met during Cuba's literacy campaigns in the 1960s - Alexis, Alejandro, Angelito, Alexander and Antonio.
Castro kept his family life secret and for decades their and their mother's identities were known only to a small circle of loyalists.
He reportedly married Ms Soto del Valle in a quiet civil ceremony in 1980, although this has never been confirmed.
Castro's death at the age of 90 was announced by his brother Raul in a state broadcast.
He said he passed away at 10.29pm local time on Friday 25 November and would be cremated before a period of mourning.