The party of former Pakistani cricket star Imran Khan has secured victory in a repeat election held in one constituency of violence-plagued Karachi, election officials say.

Khan's Tehreek-e-Insaaf (PTI) party's candidate, Arif Alvi, secured 77,659 votes to beat his closest rival Khushbakht Shujaat of the Muttahida Qaumi Movement (MQM) who polled 30,365 votes, Najib Ahmed, the election commission spokesman, said giving the unofficial results.

Polling was re-run after complaints of ballot-stuffing in the upmarket district of the vast port city, Pakistan's economic engine, during the May 11 general election.

Voting was held under tight security in 43 polling stations on Sunday, a day after Zahra Shahid Hussain, a provincial vice-president for the PTI, was shot dead outside her home in the city.

The win sets the stage for protests and counter-protests, as the city reels from Sunday's killing.

Hussain was attacked hours before re-elections took place in the NA-250 constituency of Karachi.

The motives behind the attack remained unclear, but Khan has blamed the rival MQM, which has a stronghold on Karachi.

Hussain "was leaving her home for some work when three gunmen attacked her. She thought they wanted to snatch her purse and handed it over to them but they killed her," Firdous Shamim, a local PTI leader, told the AFP news agency.

Police said all three assailants escaped after the attack late on Saturday.

"They shot her with one bullet near her chin and she could not survive," Nasir Aftab, a senior police official, told AFP.

'Charged political debate'

Al Jazeera's Imtiaz Tyab, reporting from the capital Islamabad, said that a message on Twitter sent out by Khan, accusing MQM of being behind the attack, had "charged the political debate in Pakistan".

Live Box 20135614915921114

Altaf Hussain, the MQM leader, is wanted on murder charges in Pakistan and leads his party from self-imposed exile in England.

Khan and a party spokesperson condemned the killing and denounced it as a security failure on the part of the provincial government 

The MQM is designated as a terrorist organisation by Canada, a charge it strongly denies.

Our correspondents said that while "no violence was reported during the voting period, some polling stations saw low voter turnout".