He called himself a "humble soldier" in a battle for socialism and against U.S. hegemony. He thrived on confrontation with Washington and his political opponents at home, and used those conflicts to rally his followers.
Almost the only adversary it seemed he couldn't beat was cancer.
During more than 14 years in office, his leftist politics and grandiose style polarized Venezuelans. The barrel-chested leader electrified crowds with his booming voice, and won admiration among the poor with government social programs and a folksy, nationalistic style.
His opponents seethed at the larger-than-life character who demonized them on television and ordered the expropriation of farms and businesses. Many in the middle class cringed at his bombast and complained about rising crime, soaring inflation and government economic controls.
Before his struggle with cancer, he appeared on television almost daily, frequently speaking for hours and breaking into song or philosophical discourse. He often wore the bright red of his United Socialist Party of Venezuela, or the fatigues and red beret of his army days. He had donned the same uniform in 1992 while leading an ill-fated coup attempt that first landed him in jail and then launched his political career.
The rest of the world watched as the country with the world's biggest proven oil reserves took a turn to the left under its unconventional leader, who considered himself above all else a revolutionary.
"I'm still a subversive," the president told The Associated Press in a 2007 interview, recalling his days as a rebel soldier. "I think the entire world has to be subverted."
From the start, Chavez billed himself as the heir of Simon Bolivar, who led much of South America to independence. He often spoke beneath a portrait of Bolivar and presented replicas of the liberator's sword to allies. He built a soaring mausoleum in Caracas to house the remains of "El Libertador."
Chavez also was inspired by his mentor Fidel Castro and took on the Cuban leader's role as Washington's chief antagonist in the Western Hemisphere after the ailing Castro turned over the presidency to his brother Raul in 2006. Like Castro, Chavez vilified U.S.-style capitalism while forming alliances throughout Latin America and with distant powers such as Russia, China and Iran.
Supporters eagerly raised Chavez to the pantheon of revolutionary legends ranging from Castro to Argentine-born rebel Ernesto "Che" Guevara. Chavez nurtured that cult of personality, and even as he stayed out of sight for long stretches fighting cancer, his out-sized image appeared on buildings and billboard throughout Venezuela. The airwaves boomed with his baritone mantra: "I am a nation." Supporters carried posters and wore masks of his eyes, chanting, "I am Chavez."
In the battles Chavez waged at home and abroad, he captivated his base by championing his country's poor.
"This is the path: the hard, long path, filled with doubts, filled with errors, filled with bitterness, but this is the path," Chavez told his backers in 2011. "The path is this: socialism."
He invested Venezuela's oil wealth into social programs including state-run food markets, cash benefits for poor families, free health clinics and education programs. Chavez also organized poor neighborhoods into community councils that aided his party's political machine.
Official statistics showed poverty rates declined from 50 percent at the beginning of Chavez's first term in 1999 to 32 percent in the second half of 2011.
Chavez also won support through sheer charisma and a flair for drama.
He ordered Bolivar's sword removed from the Central Bank to unsheathe at key moments, and once raised it before militia troops urging them to be ready to "give your lives, if you have to, for the Bolivarian Revolution!"
On television, he would lambast his opponents as "oligarchs," scold his aides, tell jokes, reminisce about his childhood, lecture Venezuelans on socialism and make sudden announcements, such as expelling the U.S. ambassador or ordering tanks to Venezuela's border with Colombia. Sometimes he would burst into baritone renditions of folk songs.
Chavez carried his in-your-face style to the world stage as well. In a 2006 speech to the U.N. General Assembly, he called President George W. Bush the devil, saying the podium reeked of sulfur after the U.S. president's address.
At a summit in 2007, he repeatedly called Spanish Prime Minister Jose Maria Aznar a fascist, prompting Spain's King Juan Carlos to snap at Chavez, "Why don't you shut up?"
Critics saw Chavez as a typical Latin American caudillo, a strongman who ruled through force of personality and showed disdain for democratic rules. Chavez concentrated power in his hands as his allies dominated the congress and justices seen as doing his bidding controlled the Supreme Court.
Chavez insisted Venezuela remained a vibrant democracy and denied trying to restrict free speech. But some opponents faced criminal charges and were driven into exile. Chavez's government forced one opposition-aligned television channel, RCTV, off the air by refusing to renew its license.
While Chavez trumpeted plans for communes and an egalitarian society, his rhetoric regularly conflicted with reality. Despite government seizures of companies and farmland, the balance between Venezuela's public and private sectors changed little during his presidency. And even as the poor saw their incomes rise, those gains were blunted while the country's currency weakened amid the economic controls he imposed.
Nonetheless, Chavez maintained a core of supporters who stayed loyal to their "comandante" until the end.
"Chavez masterfully exploits the disenchantment of people who feel excluded ... and he feeds on controversy whenever he can," Cristina Marcano and Alberto Barrera Tyszka wrote in their book "Hugo Chavez: The Definitive Biography of Venezuela's Controversial President."
Hugo Rafael Chavez Frias was born on July 28, 1954, in the rural town of Sabaneta in Venezuela's western plains. He was the son of a schoolteacher father and was the second of six brothers. His mother was also a schoolteacher who met her husband at age 16.
Hugo and his older brother Adan grew up with their grandmother, Rosa Ines, in a home with a dirt floor, mud walls and a roof made of palm fronds.
Chavez was a fine baseball player and hoped he might one day pitch in the U.S. major leagues. When he joined the military at age 17, he aimed to keep honing his baseball skills in the capital.
But between his army duties and drills, the young soldier immersed himself in the history of Bolivar and other Venezuelan heroes who had overthrown Spanish rule, and his political ideas began to take shape.
Chavez burst into public view in 1992 as a paratroop commander leading a military rebellion that brought tanks to the presidential palace. The coup collapsed and the plotters were imprisoned.
When Chavez was allowed to speak on television, he said his movement had only failed "for now." Chavez's short speech, and especially those two defiant words, seared him into the memory of Venezuelans and became a springboard for his career.
President Rafael Caldera, long an advocate of political reconciliation, dropped charges against Chavez and other coup plotters in 1994 and released them from prison.
Chavez then organized a new political party and ran for president in 1998, pledging to clean up Venezuela's entrenched corruption and shatter its traditional two-party system. At age 44, he became the country's youngest president in four decades of democracy with 56 percent of the vote.
After he took office on Feb. 2, 1999, Chavez called for a new constitution, and an assembly filled with his allies drafted the document. Among various changes, it lengthened presidential terms from five years to six and changed the country's name to the Bolivarian Republic of Venezuela.
Chavez was re-elected in 2000 in an election called under the new constitution. His increasingly confrontational style and close ties to Cuba, however, disenchanted many of the middle-class supporters who had voted for him, and the next several years saw bold attempts by opponents to dislodge him from power.
In 2002, he survived a short-lived coup, which began after large anti-Chavez street protests ended in shootings and bloodshed. Dissident military officers alarmed by Chavez's growing ties to Cuba detained the president and announced he had resigned. But within two days, he returned to power with the help of military loyalists amid massive protests by his supporters.
Chavez emerged a stronger president. He defeated an opposition-led strike that paralyzed the country's oil industry and fired thousands of state oil company employees.
The coup also turned Chavez more decidedly against the U.S. government, which had swiftly recognized the provisional leader who briefly replaced him. He created political and trade alliances that excluded the U.S., and he cozied up to Iran and Syria in large part, it seemed, due to their shared antagonism toward the U.S. government.
Despite the souring relationship, Chavez kept selling the bulk of Venezuela's oil to the United States.
By 2005, Chavez was espousing a new, vaguely defined "21st-century socialism." Yet the agenda didn't involve a sudden overhaul to the country's economic order, and some businesspeople continued to prosper. Those with lucrative ties to the government came to be known as the "Bolivarian bourgeoisie."
After easily winning re-election in 2006, Chavez began calling for a "multi-polar world" free of U.S. domination, part of an expanded international agenda. He boosted oil shipments to China, set up joint factories with Iran to produce tractors and cars, and sealed arms deals with Russia for assault rifles, helicopters and fighter jets. He focused on building alliances throughout Latin America and injected new energy into the region's left. Allies were elected in Bolivia, Ecuador, Argentina and other countries.
Chavez also cemented relationships with island countries in the Caribbean by selling them oil on preferential terms while severing ties with Israel, supporting the Palestinian cause and backing Iran's right to a nuclear energy program.
All the while, Chavez emphasized that it was necessary to prepare for any potential conflict with the "empire," his term for the United States.
He told the AP in 2007 that he loved the movie "Gladiator."
"It's confronting the empire, and confronting evil. ... And you end up relating to that gladiator," Chavez said as he drove across Venezuela's southern plains.
He said he felt a deep connection to those plains where he grew up, and that when died he hoped to be buried in the savanna.
"A man from the plains, from these great open spaces ... tends to be a nomad, tends not to see barriers. You don't see barriers from childhood on. What you see is the horizon," Chavez said.
Chavez wasn't shy about flaunting his government's achievements, such as free health clinics staffed by Cuban doctors, new public housing and laptops for needy children.
But even Chavez acknowledged in 2011 that one of his government's greatest weaknesses was a "lack of efficiency." He called it "a big error that many times has put in danger the government's policies."
Running a revolution ultimately left little time for a personal life. His second marriage, to journalist Marisabel Rodriguez, deteriorated in the early years of his presidency, and they divorced in 2004. In addition to their one daughter, Rosines, Chavez had three children from his first marriage, which ended before he ran for office. His daughters Maria and Rosa often appeared at his side at official events and during his trips.
Chavez acknowledged after he was diagnosed with cancer in June 2011 that he had recklessly neglected his health. He had taken to staying up late and drinking as many as 40 cups of coffee a day. He regularly summoned his Cabinet ministers to the presidential palace late at night.
Even as he appeared with head shaved while undergoing chemotherapy, he never revealed the exact location of tumors that were removed from his pelvic region, or the exact type of cancer.
Chavez exerted himself for one final election campaign in 2012 after saying tests showed he was cancer-free, and defeated younger challenger Henrique Capriles. With another six-year term in hand, he promised to keep pressing for revolutionary changes.
But two months later, he went to Cuba for a fourth cancer-related surgery, blowing a kiss to his country as he boarded the plane.
After a 10-week absence, the government announced that Chavez had returned to Venezuela and was being treated at a military hospital in Caracas. He was never seen again in public.
In his final years, Chavez frequently said Venezuela was well on its way toward socialism, and at least in his mind, there was no turning back.
His political movement, however, was mostly a one-man phenomenon. Only three days before his final surgery, Chavez named Vice President Nicolas Maduro as his chosen successor.
Now, it will be up to Venezuelans to determine whether the Chavismo movement can survive, and how it will evolve, without the leader who inspired it.