Mid-oceanic ridges are common along :
Divergent margins
According to plate tectonics, plate boundaries are of three kinds: plates move apart (divergent), move towards each other (convergent) or slide past each other (transform/shear).
At divergent margins magma rises from the mantle through the gap, cools and forms new oceanic crust; the piled-up new crust forms long underwater mountain chains such as the Mid-Atlantic Ridge. This is sea-floor spreading.
Convergent margins form trenches and fold mountains, while transform or shear margins neither create nor destroy crust.
Hence, Divergent margins.