Systemic administration of nitroglycerin, a nitric oxide donor, triggers in migraine patients a delayed attack of unknown mechanism. After puberty migraine is more prevalent in women. Attacks can be triggered by abrupt falls in plasma estrogen levels, which accounts in part for sexual dimorphism, but lacks an established neurobiological explanation. We studied the effect of nitroglycerin on the innervated area of calcitonin gene-related peptide (CGRP) and serotonin-immunoreactive afferents to the superficial laminae of the spinal portion of trigeminal nucleus caudalis, and its modulation by estrogen. In male rats, nitroglycerin produced after 4 h a significant decrease of the area innervated by CGRP-immunoreactive afferents and an increase of that covered by serotonin-immunoreactive fibres. These effects were not observed in the superficial laminae of thoracic dorsal horns. The effect of nitroglycerin was similar in ovariectomized females. In estradiol-treated ovariectomized females the area in the spinal portion of trigeminal nucleus caudalis laminae I–II covered by CGRP-immunoreactive fibres was lower and that of serotonin-immunoreactive fibres was higher than in males and for both transmitters not significantly changed after nitroglycerin. The bouton size of CGRP profiles was smaller in estradiol-treated ovariectomized females, whereas after nitroglycerin it decreased significantly but only in males and ovariectomized females. Nitroglycerin, i.e. nitric oxide, is thus able to differentially influence afferent fibres in the superficial laminae of rat spinal trigeminal nucleus caudalis. Estradiol modulates the basal expression of these transmitters and blocks the nitroglycerin effect. These data may contribute to understanding the mechanisms by which estrogens influence migraine severity and the triggering of attacks by nitric oxide.