Gestational exposure to air pollution increases the risk of autism spectrum disorder and cognitive impairments with unresolved molecular mechanisms. This study exposed C57BL/6J mice throughout gestation to urban-derived nanosized particulate matter (nPM). Young adult male and female offspring were studied for behavioral and metabolic changes using forced swim test, fat gain, glucose tolerance, and hippocampal transcriptome. Gestational nPM exposure caused increased depressive behaviors, decreased neurogenesis in the dentate gyrus, and increased glucose tolerance in adult male offspring. Both sexes gained fat and body weight. Gestational nPM exposure induced 29 differentially expressed genes (DEGs) in adult hippocampus related to cytokine production, IL17a signaling, and dopamine degradation in both sexes. Stratification by sex showed twofold more DEGs in males than females (69 vs 37), as well as male-specific enrichment of DEGs mediating serotonin signaling, endocytosis, Gαi, and cAMP signaling. Gene co-expression analysis (WCGNA) identified a module of 43 genes with divergent responses to nPM between the sexes. Chronic changes in 14 DEGs (e.g., microRNA9-1) were associated with depressive behaviors, adiposity and glucose intolerance. These genes enriched neuroimmune pathways such as HMGB1 and TLR4. Based on cerebral cortex transcriptome data of neonates, we traced the initial nPM responses of HMGB1 pathway. In vitro, mixed glia responded to 24 h nPM with lower HMGB1 protein and increased proinflammatory cytokines. This response was ameliorated by TLR4 knockdown. In sum, we identified transcriptional changes that could be associated with air pollution-mediated behavioral and phenotypic changes. These identified genes merit further mechanistic studies for therapeutic intervention development.