As rocks move past each other along a fault, their rough surfaces catch temporarily, halting movement along the fault. However, forces keep driving the rocks to move, causing stress to build up. When the rocks are stressed beyond the elastic limit, they break and move along the fault causing earthquakes to occur.