Prenatal exposure to viral pathogens has been known to cause the development of neuropsychiatric disorders in adulthood. Furthermore, COVID-19 has been associated with a variety of neurological manifestations, raising the question of whether in utero SARS-CoV-2 exposure can affect neurodevelopment, resulting in long-lasting behavioral and cognitive deficits. Using a human ACE2-knock-in mouse model, we have previously shown that prenatal exposure to SARS-CoV-2 at later stages of development leads to fetal brain infection and gliosis in the hippocampus and cortex. In this study, we aimed to determine whether infection of the fetal brain results in long-term neuroanatomical alterations of the cortex and hippocampus or in any cognitive deficits in adulthood. Here, we show that infected mice developed slower and weighed less in adulthood. We also found altered hippocampal and amygdala volume and aberrant newborn neuron morphology in the hippocampus of adult mice infected in utero. Furthermore, we observed sex-dependent alterations in anxiety-like behavior and locomotion, as well as hippocampal-dependent spatial memory. Taken together, our study reveals long-lasting neurological and cognitive changes as a result of prenatal SARS-CoV-2 infection, identifying a window for early intervention and highlighting the importance of immunization and antiviral intervention in pregnant women.