Pakistani President Pervez Musharraf says all foreign students at madrassas, or religious schools, some 1,400 pupils, must leave the country.
Madrassas must not be misused for extremism, says Musharraf
"Any (foreigners) in the madrassas - even dual nationality holders - will leave Pakistan," Gen Musharraf said.
This is the latest in a series of measures the president has announced in a renewed clampdown on extremism.
Madrassas have been in the spotlight after one of the London bombers was reported to have studied at one.
Gen Musharraf told foreign journalists in Rawalpindi: "They must leave. We will not issue visas to such people.
"We will not allow madrassas to be misused for extremism, hatred being projected in our society."
No new visas will be issued to foreigners wishing to study in the schools.
But the BBC's Aamer Ahmed Khan says it is not clear what effect these measures will have on extremism as the more militant students work at unregulated madrassas that have survived previous crackdowns.
An ordinance would be adopted "in the coming days" on the new move, Gen Musharraf said.
He also told journalists that action would be taken against any of the madrassas that did not register with the authorities.
The president had previously announced all schools must register before December.
Pakistani forces have detained hundreds of clerics and suspected militants since President Musharraf announced a new crackdown on 15 July.
British Prime Minister Tony Blair called on Pakistan to curb extremists and radical madrassas in the wake of the London bombings of 7 July.
The Jamia Manzoorul Islam madrassa in Lahore denies links to a London bomber
Gen Musharraf said on Friday that no arrests in Pakistan were directly related to the bombings.
"The investigation is going on. It's a little premature to draw a conclusion. It's a very tedious job," he said.
The president also vowed to crack down on anti-Western hate speeches in mosques or in recordings.
In a recent visit to a Lahore madrassa, our correspondent Aamer Ahmed Khan found foreign students visibly uncomfortable with the links being drawn by the media between terrorism and religious education.
The students said they were there simply to learn and were "more disappointed than angry" at the terror links.
It is estimated that there are around 20,000 madrassas in Pakistan.
According to the Pakistani newspaper, The News, there are around 1.7m students at the institutions, mainly from poor rural families.
The number of foreigners dropped sharply after the 11 September attacks in the US.
New rules after the attacks obliged foreigners to state in their visa applications where they planned to study. The visas became invalid if they left the madrassa.