Synthesis of sugars from simple carbon sources is critical for survival of animals under limited nutrient availability. Thus, sugar-synthesizing enzymes should be present across the entire metazoan spectrum. Here, we explore the evolution of glucose and trehalose synthesis using a phylogenetic analysis of enzymes specific for the two pathways. Our analysis reveals that the production of trehalose is the more ancestral biochemical process, found in single cell organisms and primitive metazoans, but also in insects. The gluconeogenic-specific enzyme glucose-6-phosphatase (G6Pase) first appears in Cnidaria, but is also present in Echinodermata, Mollusca and Vertebrata. Intriguingly, some species of nematodes and arthropods possess the genes for both pathways. Moreover, expression data from Drosophila suggests that G6Pase and, hence, gluconeogenesis, initially had a neuronal function. We speculate that in insects-and possibly in some vertebrates-gluconeogenesis may be used as a means of neuronal signaling.