Rift valleys are formed through the process of faulting. Faulting occurs when there is tensional stress in the Earth's crust, causing it to crack and split apart. The split forms two separate blocks of crust, with one side moving downwards and the other side moving upwards, creating a steep-sided valley in between. This process is often associated with the movement of tectonic plates, where the plates move apart and create a rift zone in the Earth's crust. Over time, erosion and other geological processes may modify the shape of the rift valley, but the initial formation is due to faulting.