Cytomegalovirus (CMV) infection can generate debilitating disease in immunocompromised individuals and neonates. It is also the most common infectious cause of congenital birth defects in infected fetuses. Available anti-CMV drugs are partially effective but are limited by some toxicity, potential viral resistance, and are not recommended for fetal exposure. Valproate, valpromide, and valnoctamide have been used for many years to treat epilepsy and mood disorders. We report for the first time that, in contrast to the virus-enhancing actions of valproate, valpromide and valnoctamide evoke a substantial and specific inhibition of mouse and human CMV in vitro. In vivo, both drugs safely attenuate mouse CMV, improving survival, body weight, and developmental maturation of infected newborns. The compounds act by a novel mechanism that interferes with CMV attachment to the cell. Our work provides a novel potential direction for CMV therapeutics through repositioning of agents already approved for use in psychiatric disorders.