New Zealanders were also jolted awake on Sunday night, when a 4.8 quake hit at 11.28pm in the Cook Strait, 30km west of Wellington. Thousands reported feeling the shake.
Geonet seismologist John Ristau said the closeness in timing of the earthquakes was a coincidence.
"You can get cases where large earthquakes trigger smaller ones nearby, but these are quite spread apart."
Ristau said there was no evidence that earthquakes of any magnitude were occurring more frequently.
He also noted compared to other earthquakes, California's 4.7 and New Zealand's 4.5 shakes were relatively small and quite common. Even the Costa Rica quake was not uncommon for South America, he noted.
"Earthquakes are random and chaotic, there's fluctuations in when they occur... Over a long term period, it averages out and you'll still get about the same number of different types of magnitude earthquakes per year."