The Drosophila melanogaster ventral nerve cord derives from neural progenitor cells called neuroblasts. Individual neuroblasts have unique gene expression profiles and give rise to distinct clones of neurons and glia. The specification of neuroblast identity provides a cell intrinsic mechanism which ultimately results in the generation of progeny which are different from each other. Segment polarity genes have a dual function in early neurogenesis: within distinct regions of the neuroectoderm, they are required both for neuroblast formation and for the specification of neuroblast identity. Previous studies of segment polarity gene function largely focused on neuroblasts that arise within the posterior part of the segment. Here we show that the segment polarity gene midline is required for neuroblast formation in the anterior-most part of the segment. Moreover, midline contributes to the specification of anterior neuroblast identity by negatively regulating the expression of Wingless and positively regulating the expression of Mirror. In the posterior-most part of the segment, midline and its paralog, H15, have partially redundant functions in the regulation of the NB marker Eagle. Hence, the segment polarity genes midline and H15 play an important role in the development of the ventral nerve cord in the anterior- and posterior-most part of the segment.