The giraffe has an extremely elongated neck, which can be up to 2–2.4 m (6.6–7.9 ft) in length, accounting for much of the animal's vertical height. The long neck results from a disproportionate lengthening of the cervical vertebrae, not from the addition of more vertebrae. Each cervical vertebra is over 28 cm (11 in) long. They comprise 52–54 percent of the length of the giraffe's vertebral column, compared with the 27–33 percent typical of similar large ungulates, including the giraffe’s closest living relative, the okapi. This elongation largely takes place after birth, as giraffe mothers would have a difficult time giving birth to young with the same neck proportions as adults. The giraffe's head and neck are held up by large muscles and a nuchal ligament, which are anchored by long dorsal spines on the anterior thoracic vertebrae, giving the animal a hump.
The giraffe's neck vertebrae have ball and socket joints. In particular, the atlas–axis joint (C1 and C2) allows the animal to tilt its head vertically and reach more branches with the tongue. The point of articulation between the cervical and thoracic vertebrae of giraffes is shifted to lie between the first and second thoracic vertebrae (T1 and T2), unlike most other ruminants where the articulation is between the seventh cervical vertebra (C7) and T1. This allows C7 to contribute directly to increased neck length and has given rise to the suggestion that T1 is actually C8, and that giraffes have added an extra cervical vertebra. However, this proposition is not generally accepted, as T1 has other morphological features, such as an articulating rib, deemed diagnostic of thoracic vertebrae, and because exceptions to the mammalian limit of seven cervical vertebrae are generally characterized by increased neurological anomalies and maladies.
Another theory, the sexual selection hypothesis, proposes that the long necks evolved as a secondary sexual characteristic, giving males an advantage in "necking" contests to establish dominance and obtain access to sexually receptive females. In support of this theory, necks are longer and heavier for males than females of the same age, and the former do not employ other forms of combat. However, one objection is that it fails to explain why female giraffes also have long necks. It has also been proposed that the neck serves to give the animal greater vigilance.