The U.S. Geological Survey says the quake struck 3 miles north of Fontana at 1:35 a.m. Wednesday.
The Fontana Police Department and San Bernardino Sheriff's Department both say there were no immediate reports of damage or injuries.
Most residents posting to the USGS community Internet intensity map reported the quake felt light to weak. Some residents of Fontana and San Bernardino reported the shaking as moderate.