A 6.4 magnitude earthquake has struck southern Taiwan near the city of Tainan, triggering at least one building to collapse trapping scores of people.
While there were no immediate reports of deaths following the quake, but the local fire brigade reported that 123 people had to be rescued from a seven-storey collapsed building in the city.
Images posted on social media also showed a collapsed building and several people trying to rescue those who were trapped. Another building was also shown partially collapsed.  
The US Geological Survey said the earthquake, initially reported as a magnitude 6.7, was centred 43km southeast of the city of nearly two million people.
The quake was very shallow, at a depth of 10km, which would have amplified its effects, the USGS said.
At least five aftershocks of 3.8-magnitude or more shook Tainan about half an hour after the initial quake, according to Taiwan's Central Weather Bureau.
Taiwan's China Post newspaper said on its website that more than one building collapsed in the quake.
"Collapsed buildings reported in Tainan, with rescue workers arriving on scene. The city government there has set up a level one emergency response centre. Onlookers are urged not to block access to emergency crews moving into the area," the newspaper said.
Tainan city's fire department said earlier that it was on its way to the site of one building that had partially collapsed and Liu Shih-chung, an official with the Tainan City Government, said the city had set up an emergency response centre.
Many people in Taiwan said the tremor was strong. "I hugged the wall and put my face to the wall," Pao-feng Wu, a Tainan resident, told Reuters after the quake hit.
The quake hits the island republic as it gears up for the annual Lunar New Year, one of the biggest holidays there and in other predominantly Chinese countries.  
Taiwan lies near the junction of two tectonic plates and is regularly hit by earthquakes.
In September 1999, a powerful quake also hit southern Taiwan killing an estimated 2,400 people.