Insect steroid hormones (ecdysteroids) are important for female reproduction in many insect species and are required for the initiation and coordination of vital developmental processes. Ecdysteroids are also important for adult male physiology and behavior, but their exact function and site of synthesis remains unclear, although previous studies suggest that the reproductive system may be their source. We have examined expression profiles of the ecdysteroidogenic Halloween genes, during development and in adults of the flour beetle Tribolium castaneum. Genes required for the biosynthesis of ecdysone (E), the precursor of the molting hormone 20-hydroxyecdysone (20E), are expressed in the tubular accessory glands (TAGs) of adult males. In contrast, expression of the gene encoding the enzyme mediating 20E synthesis was detected in the ovaries of females. Further, Spookiest (Spot), an enzyme presumably required for endowing tissues with competence to produce ecdysteroids, is male specific and predominantly expressed in the TAGs. We also show that prothoracicotropic hormone (PTTH), a regulator of E synthesis during larval development, regulates ecdysteroid levels in the adult stage in Drosophila melanogaster and the gene for its receptor Torso seems to be expressed specifically in the accessory glands of males. The composite results suggest strongly that the accessory glands of adult male insects are the main source of E, but not 20E. The finding of a possible male-specific source of E raises the possibility that E and 20E have sex-specific roles analogous to the vertebrate sex steroids, where males produce primarily testosterone, the precursor of estradiol. Furthermore this study provides the first evidence that PTTH regulates ecdysteroid synthesis in the adult stage and could explain the original finding that some adult insects are a rich source of PTTH.