No tsunami warning was issued, the agency added.
The earthquake occurred at 12.51 a.m., with its epicenter at a latitude of 28.8 degrees north and a longitude of 128.3 degrees east, and at a depth of 160 km.
There were no immediate reports of injuries or damages.