Erratic and mercurial, he fancied himself a political philosopher, practiced an unorthodox and deadly diplomacy, and cut a sometimes cartoonish figure in flowing robes and dark sunglasses, surrounded by heavily armed female bodyguards.
It was as an actor on the world stage, though, that he showed his gift for unpredictability. President Reagan called him "the mad dog of the Middle East." Anwar Sadat, the late Egyptian president, once said Kadafi was "either 100% crazy or possessed of the devil." Others thought he was both.
PHOTOS: Moammar Kadafi | 1942 - 2011
When Kadafi took power in 1969, he embraced an adventurist foreign policy, championing his dream of a utopian, Islamic nation that would span northern Africa. He eschewed both communism and capitalism and called his political system jamahiriya, or "republic of the masses."
He soon evolved into an international troublemaker: His Libya funded guerrilla groups, built a nuclear weapons program and launched terrorist attacks on the West — including the 1988 bombing of Pan Am Flight 103 over Lockerbie, Scotland. Then, as the United States began hunting terrorists worldwide, he did a diplomatic U-turn, making oil deals with the West and providing back-channel help for American spy agencies battling international terrorists.
It was the "Arab Spring" uprising against tyrants in the Middle East that ignited an internal rebellion against Kadafi, turned his regime into a NATO target and led to the end of his reign. On Thursday, in his hometown of Surt on the Mediterranean Sea, it was over. He was 69.
The only son of an illiterate Bedouin herder, Kadafi was born in 1942 in a goatskin tent about 20 miles from Surt and spent his early years living the life of desert nomads. His father scrimped and borrowed to send his son to a nearby Muslim school. It was there that Kadafi listened daily to a Cairo radio station that carried speeches by Egyptian President Gamal Abdel Nasser, a pan-Arabist and leader of the independence movement in the Arab world.
"We must go into the army," Kadafi told his classmates. "That is the only way to make a revolution."
He was 14 when he led his first demonstration in support of Nasser, and by the time he was 19 he had taken the first step toward formulating a plan to overthrow the corrupt, pro-Western regime of Libya's King Idris by entering the Royal Military Academy at Benghazi.
Kadafi surrounded himself with fellow conspirators and imposed the same moral standards on them that he demanded of himself: abstinence from tobacco and alcohol, no womanizing or gambling, prayers five times a day. In 1966, he studied armored warfare tactics in Britain, where he learned to speak English.
On Sept. 1, 1969, Kadafi, a 27-year-old signal corps captain in the Libyan army, and his group of "free officers" overthrew Idris, who was out of the country, in a bloodless coup. Kadafi himself went to the state radio station to broadcast the news to the Libyan people.
"Give us your hands. Open up your hearts to us," he said. "Forget past misfortunes and as one people prepare to face the enemies of Islam, the enemies of humanity.... We shall resurrect our heritage. We shall avenge our wounded dignity and restore the rights which have been wrested from us."
He moved quickly in an effort to change Libya overnight. He ordered the closure of the United States' huge Wheelus air base — negotiations were carried out amicably between Washington and Tripoli — and the evacuation of British military bases. He expelled 20,000 Italians and nationalized most of the oil industry. Nightclubs and casinos were shuttered, alcohol was banned, and unmarried women who became pregnant were flogged and sent off to reformatories.
Angered by the amount of time his bureaucrats spent reading newspapers and drinking coffee, he had most of the desks and chairs removed from government offices. The bureaucrats were not fazed; they took to reading their newspapers leaning against the walls and brewing their coffee on the concrete floors.
During his first full decade in power, Kadafi was a popular leader. He invested some of the nation's $50 billion in annual oil revenue in developing agriculture and building schools, hospitals and housing.
In the 1970s, Kadafi developed his so-called Third Universal Theory. It was his blueprint for a socialistic welfare state in which there would be no laws, no money, no government, no private enterprise. The leader — Kadafi never called himself president — published this philosophy in a slim volume called "The Green Book."
He managed to attract a group of leftist scholars to Libya in 1979 to debate the wisdom of "The Green Book," though most impartial observers found it most noteworthy for its naivete and lack of depth. One example from its text: "Woman is a female and man, being a male, does not … get pregnant … [and] is not liable to the feebleness which woman, being a female, suffers."