Unofficial results announced after separate votes in the federal and provincial assemblies showed Asif Ali Zardari won an overwhelming majority, bolstered by public loyalty to his late wife and hopes that he can pull the country out of its economic doldrums.
Pro-Zardari lawmakers, some in tears, shouted "Long live Bhutto!" as the vote tallies came in. The couple's two jubilant but tearful daughters, one carrying a portrait of their late mother, smiled and hugged friends in the gallery of the National Assembly.
But Saturday also brought a brutal reminder of the threats to the nuclear-armed nation's stability as a suicide car bomber killed at least 17 people and wounded dozens near the northwestern city of Peshawar.
The blast destroyed a police checkpoint and collapsed several nearby shops. Civilians dug frantically with their hands for possible survivors.
Head of the main ruling party, Zardari becomes one of the most powerful civilian leaders in Pakistan's turbulent 61-year history. Last month, he marshaled a coalition that forced longtime U.S. ally Pervez Musharraf to quit as head of state.
Zardari, a novice leader untested on the international stage and stained by past corruption allegations, takes over at a critical time for the volatile Muslim nation of more than 160 million.
The economy is crumbling, and Saturday's attack was the latest in a string of suicide bombings usually claimed by Islamic militants who have steadily gained strength since Pakistan joined the U.S. war on terrorism in 2001.
On Saturday evening, Zardari hugged and shook hands with supporters and well-wishers who attended a celebratory dinner in the gardens of the prime minister's residence on a hill overlooking the capital.
In a brief speech, he rejected criticism that he would be a divisive president and took another swipe at Musharraf, a former general.
"To those who would say that the People's Party or the presidency would be controversial under our guardianship, under our stewardship, I would say listen to democracy," he said.
Echoing one of his late wife's favorite slogans, he said "democracy was the best revenge" against military rulers.
Washington is pressing Pakistan hard to eradicate Taliban and al Qaeda havens near its border with Afghanistan. An American-led ground attack, said to have killed at least 15 in Pakistani territory Wednesday, sparked outrage and embarrassed Zardari's party.
The U.S. government congratulated Zardari. Secretary of State Condoleezza Rice, who has not met Zardari but has spoken with him by phone, said she looked forward to working with him.
"I've been impressed by some of the things he has said about the challenges that Pakistan faces, about the centrality of fighting terrorism, about the fact that the terrorism fight is Pakistan's fight and also his very strong words of friendship and alliance with the United States," Rice said.
Tariq Raza, a 45-year-old teacher in the central city of Multan, called Zardari's victory a last chance for his party to prove it can improve the economy and fight terrorism.
"The PPP is in power just because of the sympathy vote after the brutal murder of Benazir Bhutto," Raza said. "We want him to save Pakistan from becoming Iraq and Afghanistan."
Musharraf, who seized power in a 1999 military coup, yielded his army post last year after imposing a state of emergency to fend off legal challenges to winning another term, this time as a civilian head of state.
Zardari says he will relinquish some of the powers accumulated by Musharraf but has not made clear how far he will go, sustaining concern that one strongman is replacing another.
Interior Ministry chief Rehman Malik said Saturday's bombing was an attempt to upset the progress of a country riven by ethnic and sectarian divides toward a more stable democracy.
If a reported Taliban claim of responsibility proves correct, "They'll have to pay for it," he said.
Like his late wife, Zardari is generally considered a pro-West liberal. He is not expected to change Musharraf's commitment to the U.S. war on terrorism, insisting the battle against militants is Pakistan's own war. But a key test will be how much clout Zardari wields over the powerful military, which has failed to halt the Taliban's rise in the volatile northwest.
The president has the power to dissolve Parliament and appoint army chiefs, and chairs the joint civilian-military committee that controls Pakistan's nuclear weapons.
Zardari, who has spent about 11 years in prison on corruption allegations but was never convicted, has surprised many with his ability to concentrate power since his wife was killed in a December gun-and-bomb attack and he inherited her party's leadership.
After ex-Prime Minister Nawaz Sharif's party switched to the opposition last month, Zardari quickly won support from smaller parties, suggesting he could provide some stability as the country faces soaring inflation, power shortages and widening trade and budget deficits.
Saturday's voting bore that out.
A tally of the unofficial results showed Zardari with 488 of the 685 votes, based on a formula that gave each of the four provincial assemblies equal representation and left most of the say with federal lawmakers.
Saeed-uz-Zaman Siddiqui, a former judge nominated by Sharif's party, was second with 153. Mushahid Hussain, a senator from the pro-Musharraf party routed in February parliamentary elections, was last with 44.
The Election Commission was expected to certify the results later Saturday.
Zardari, the son of a landowning businessman and tribal chief from the southern province of Sindh, wed Bhutto in an arranged marriage in 1987. Many Pakistanis call him "Mr. 10 Percent," a reference to accusations he pocketed commissions on government contracts during her two terms as prime minister.
After Bhutto was killed, Zardari returned to Pakistan from exile, seized the reins of her party and led it to victory in the February elections.