Earthquakes occur when underground rock suddenly breaks and moves rapidly along a fault, which is a fracture in the Earth's crust. This sudden movement releases stored-up elastic strain energy caused by tectonic forces, generating seismic waves that make the ground shake. The rocks on either side of the fault build up stress as tectonic plates slowly push, pull, or slide past each other, and when this stress overcomes friction, the rocks slip and cause an earthquake. The location underground where the rock first breaks is called the focus, and the point on the surface above it is the epicenter. This process is primarily due to the movement of tectonic plates on the Earth's crust and mantle, which constantly shift and interact at their boundaries, causing most earthquakes near those regions.