The quake was centered about 30 miles to the south of the Punta de Burica peninsula, south of the border between Panama and Costa Rica. It hit at 2:15 p.m. Pacific Time.
A shake map from the USGS indicates shaking was felt throughout the region, as far north as the border between Costa Rica and Nicaragua and east past Panama City.
A Costa Rica man who lives about 100 miles north of the quake tweeted that he felt "moderate rolling shocks first, then abrupt strong shock."
There were no immediate reports of damage and no tsunami warning was issued.
RELATED | How to make your own earthquake kit
WATCH | Earthquake expert Dr. Lucy Jones answers your questions