There were no reports of casualties in the early morning earthquake, local officials said.
Hindu Kush mountains were the epicentre of the 5.1 magnitude earthquake at the depth of 73 kilometres, a meteorological department official said.
The tremors of the quake were felt in Chitral, Malakand and adjoining areas. People rushed out of their homes due to fear and panic.
Pakistan straddles part of the boundary where the Indian and Eurasian tectonic plates meet, making the country susceptible to earthquakes.