He was demonised by the United States and its allies but admired by many leftists around the world.
Havana: Fidel Castro, the Cuban revolutionary leader who built a communist state on the doorstep of the United States and for five decades defied US efforts to topple him, has died, Cuban television said. He was 90.
Here are some comments on Castro from his friends and foes over the years.
"Castro is not just another Latin American dictator, a petty tyrant bent merely on personal power and gain. His ambitions extend far beyond his own shores," Former U.S. President John F. Kennedy, from "The Quotable Mr. Kennedy," edited by Gerald C. Gardner, 1962.
"Fidel, for me, is a grand master. A wise man should never die; a man like Fidel will never die, because he will always be part of the people," Former Venezuelan President Hugo Chavez, in a January 2007 speech.
"Fidel Castro had Americans murdered illegally, and that was wrong, too. And I'm proud that we have a blockade against people who kill innocent Americans," Former U.S. President Bill Clinton, in 1996, after Cuba killed four U.S. citizens when it shot down two civilian planes belonging to a Cuban-American group that had agitated against the Castro government and had repeatedly flown into Cuban air space.
"From its earliest days, the Cuban revolution has been a source of inspiration for all those who value freedom. We admire the sacrifices of the Cuban people in maintaining their independence and sovereignty in the face of the vicious imperialist and orchestrated campaign to destroy the awesome force of the Cuban revolution. Long live the Cuban Revolution! Long live comrade Fidel Castro," Former South African President Nelson Mandela, in a July 1991 speech.
"I remember Herbert Matthews' reports on Castro before he came to power, calling him a democrat and the hope of Cuba. And to some of you who are really too young to remember this, even people around our country were calling him the George Washington of Cuba, and George rolled over in his grave," U.S. President Ronald Reagan, on March 5, 1986.
"Fidel Castro is there to win. His attitude in the face of defeat, even in the most minimal actions of everyday life, would seem to obey a private logic: he does not even admit it, and does not have a minute's peace until he succeeds in inverting the terms and converting it into victory," Nobel laureate Gabriel Garcia Marquez, writing in Granma on the eve of Castro's 80th birthday.
"The best thing that Fidel Castro left us is the lesson that we don't want any more Fidel Castros in Cuba. The lesson is that a man like that ends up absorbing the whole nation, ends up seeing himself as the embodiment of the homeland, and ends up simply taking away our nationality. The lesson of Fidel Castro is no more Fidel Castros. Some people admire him, but they admire him for what they think he was, not for who he really was. Staying in power that long is no merit," Dissident blogger Yoani Sanchez, to Reuters in May 2014.
"Whatever we may think of him, he is going to be a great factor in the development of Cuba and very possibly in Latin American affairs generally. He seems to be sincere. He is either incredibly naive about communism or under communist discipline my guess is the former, and as I have already implied his ideas as to how to run a government or an economy are less developed than those of almost any figure I have met in 50 countries," Richard Nixon, who was then the U.S. vice president, in a memorandum following a three-hour meeting with Castro on April 19, 1959.
"On December 18, 1956, Fidel and I were in the foothills of the Sierra Maestra, in a place called Cinco Palmas. After our first hug his first question was: 'How many rifles do you have?' I answered five. And he said, 'I have two. That makes seven. Now we can win the war," Raul Castro, quoted in the 2009 book "This is Fidel," by Luis Baez.
"It didn't take much to prompt me to join any revolution against a tyrant, but Fidel struck me as an extraordinary man. He had exceptional faith that once we left for Cuba (from Mexico) we would arrive. That once we arrived we would fight. And once we fought we would win. I shared his optimism. I had to, to fight, to achieve. Stop crying and fight," Ernesto "Che" Guevara, in a letter to his parents, 1955.
"A man of great charisma. He's brave, Fidel Castro. A politician, with an iron fist. He stays strong. He put his close friend in front of the firing squad. I would have given him a life sentence or expelled him from the country, but he had him shot." - Former Chilean military dictator General Augusto Pinochet, regarding Castro's treatment of General Arnaldo Ochoa, executed for treason in July 1989.
"He would tell us to place a canon here, move a tank over there. Where to attack, how to do it, with how many men, et cetera. He had it all at his fingertips. And most of the time he was right,” Defence Minister Leopoldo Cintra Frias, regarding Fidel's instructions in the Angola war, in Havana, 1996.
"At a time when almost the entire communist world marches towards democracy, Fidel Castro has gone against public opinion and refuses to accept any kind of change or anything that suggests perestroika or democracy. A profound philosopher, he has made it clear that material things are transient, to such a degree that there are virtually no material things in Cuba," Cuban dissident writer Reinaldo Arenas, in an essay written before his death in 1990 and published by Spanish newspaper El Pais in 2006.