The homeobox gene tinman and the nuclear receptor gene seven-up are expressed in mutually exclusive dorsal vessel cells in Drosophila, however, the physiological reason for this distinction is not known. We demonstrate that tin and svp-lacZ expression persists through the larval stage to the adult stage in the same pattern of cells expressing these genes in the embryo. In the larva, six pairs of Svp-expressing cells form muscular ostia, which permit hemolymph to enter the heart for circulation, however, more anterior Svp-expressing cells form the wall of the dorsal vessel. During pupation, the adult heart forms from a chimera of larval and imaginal muscle fibers. The portion of the dorsal vessel containing the larval ostia is histolyzed and the anterior Svp-expressing cells metamorphose into imaginal ostia. This is the first demonstration that the significant molecular diversity of cardial cells identified in the embryonic heart correlates with the formation of physiologically and functionally distinct muscle cells in the animal. Furthermore, our experiments define the cellular changes that occur as the larval heart is remodeled into an imaginal structure in an important model organism.