Seafloor spreading centres show a regular along-axis segmentation thought to be produced by a segmented magma supply in the passively upwelling mantle. On the other hand, continental rifts are segmented by large offset normal faults, and many lack magmatism. It is unclear how, when and where the ubiquitous segmented melt zones are emplaced during the continental rupture process. Between 14 September and 4 October 2005, 163 earthquakes (magnitudes greater than 3.9) and a volcanic eruption occurred within the approximately 60-km-long Dabbahu magmatic segment of the Afar rift, a nascent seafloor spreading centre in stretched continental lithosphere. Here we present a three-dimensional deformation field for the Dabbahu rifting episode derived from satellite radar data, which shows that the entire segment ruptured, making it the largest to have occurred on land in the era of satellite geodesy. Simple elastic modelling shows that the magmatic segment opened by up to 8 m, yet seismic rupture can account for only 8 per cent of the observed deformation. Magma was injected along a dyke between depths of 2 and 9 km, corresponding to a total intrusion volume of approximately 2.5 km3. Much of the magma appears to have originated from shallow chambers beneath Dabbahu and Gabho volcanoes at the northern end of the segment, where an explosive fissural eruption occurred on 26 September 2005. Although comparable in magnitude to the ten year (1975-84) Krafla events in Iceland, seismic data suggest that most of the Dabbahu dyke intrusion occurred in less than a week. Thus, magma intrusion via dyking, rather than segmented normal faulting, maintains and probably initiated the along-axis segmentation along this sector of the Nubia-Arabia plate boundary.