The quake struck at a depth of 22 kilometers (14 miles) under the seabed in the Philippines' Batanes Islands region at 0157 GMT, the US Geological Survey said.
A blogger from Taiwan The Taiwan Chronicles felt the apartment bounce and things falling off the shelf during the quake.
There were no immediate reports of any casualties or damage and no tsunami warning was issued.
The Philippine Institute of Volcanology and Seismology put the quake about 76 kilometres west of the Batanes town of Basco.
The quake was felt strongly in Basco but was barely noticed in the northern provinces of the Philippines' main island of Luzon, the institute said.
Batanes Governor Telesforo Castillejos said that some houses had cracks on their walls after the quake but there were no casualties reported so far.
There were some weaker aftershocks and residents in some coastal areas were told to evacuate their homes as a precautionary measure in case of a tsunami, he added.
"The quake was very strong," he said on ABS-CBN television. "It jolted the whole island. It rocked the island almost for a whole minute."
The quake was also felt in southern counties of Taiwan, where the Central Weather Bureau measured it at 6.8 on the Richter scale and at a depth of 46 kilometres.