ISLAMABAD — Tens of thousands of antigovernment protesters gathered in Pakistan’s capital Islamabad late Friday in the pouring rain following the arrival of convoys led by a cricket star-turned-politician and a fiery anti-Taliban cleric.
Twin protests led by Imran Khan and the cleric Tahir-ul-Qadri represent the biggest challenge yet to Prime Minister Nawaz Sharif’s year-old government, and security had been tightened across the capital amid fears of unrest in a country with a long history of chaotic politics and coups.
The protesters left the eastern city of Lahore on Thursday, vowing to march to the capital and camp out there until their demands for a new government are met. Despite the darkness and the lashing rain, the crowds swelled as they entered Islamabad shortly before midnight.
Police estimated some 60,000 people took part in the protests.
The protests were festive despite the rain, with demonstrators waving national and party flags and dancing to drum beats and patriotic songs.
Female supporters of Qadri wearing headscarves lined the roads and waved to his convoy as it entered the city.
As he approached the Islamabad airport, Khan tweeted that he would stage a sit-in on the city’s main Kashmir Highway. ‘‘Sharif should have his resignation ready,’’ he said.
A spokesman for Qadri, Shahid Mursaleen, said the cleric would deliver a speech on Saturday to call for Sharif’s removal and immediate arrest.
Sharif says he is ready to meet with his opponents but has given no indication that he would step down.
His critics accuse him of vote fraud during the election that brought him to power last year.
Sharif’s spokesman, Pervaiz Rashid, condemned the ‘‘irresponsible behavior and actions’’ of his opponents.
‘‘Pakistan is not a banana republic, where a few thousand people come and seek the resignation of the country’s prime minister,’’ he told a local news channel.
Earlier Friday, as the march led by Khan passed through the city of Gujranwala, supporters of Sharif’s Pakistan Muslim League-N hurled stones at the convoy, said Khan, who was unharmed.
PML-N leader Rana Sanaullah told the Dawn news channel that both sides threw stones at each other.
Mohammed Azeem, a police officer in Gujranwala, about 40 miles from Lahore, said some 200 ruling party supporters clashed with Khan’s protesters but that ‘‘the situation is under control.’’
Both Khan and Qadri have vowed to bring one million of their followers into the streets of Islamabad, a city of roughly 1.7 million inhabitants.
Thousands of riot police have been deployed across the capital. Authorities set up shipping containers to block traffic and cut off cellphone service in some areas.
Interior Minister Chaudhry Nisar Ali Khan apologized Thursday for the city’s paralysis, insisting the measures were for the residents’ own safety and warning that demonstrators would face ‘‘an iron hand’’ if they try to disrupt law and order.
The protests represent the toughest challenge yet for Sharif, who won a landslide election victory in May 2013. Khan, who led Pakistan to victory in the 1992 cricket World Cup, heads the third largest party in parliament.
The army still wields great influence in Pakistan, which is battling several militant groups, but has not taken sides in the protests. There are fears, however, that political unrest could prompt the military to intervene.
Late Thursday, militants tried to storm two air bases in the southwestern city of Quetta, sparking a gun battle that killed 10 attackers, police said.
Police chief Muhammad Amlish said seven security personnel were wounded in the attack.
He said the attackers used guns and grenades as they tried to enter the Smungli and Khalid military bases on a sprawling complex next to the city’s airport.