Methionine sulfoxide reductase B (MsrB) is involved in oxidative stress or defense responses in plants. However, little is known about its role in legume-rhizobium symbiosis. In this study, an MsrB gene was identified from Astragalus sinicus and its function in symbiosis was characterized. AsMsrB was induced under phosphorus starvation and displayed different expression patterns under symbiotic and nonsymbiotic conditions. Hydrogen peroxide or methyl viologen treatment enhanced the transcript level of AsMsrB in roots and nodules. Subcellular localization showed that AsMsrB was localized in the cytoplasm of onion epidermal cells and co-localized with rhizobia in nodules. Plants with AsMsrB-RNAi hairy roots exhibited significant decreases in nodule number, nodule nitrogenase activity and fresh weight of the aerial part, as well as an abnormal nodule and symbiosome development. Statistical analysis of infection events showed that plants with AsMsrB-RNAi hairy roots had significant decreases in the number of root hair curling events, infection threads and nodule primordia compared with the control. The content of hydrogen peroxide increased in AsMsrB-RNAi roots but decreased in AsMsrB overexpression roots at the early stage of infection. The transcriptome analysis showed synergistic modulations of the expression of genes involved in reactive oxygen species generation and scavenging, defense and pathogenesis and early nodulation. In addition, a candidate protein interacting with AsMsrB was identified and confirmed by bimolecular fluorescence complementation. Taken together, our results indicate that AsMsrB plays an essential role in nodule development and symbiotic nitrogen fixation by affecting the redox homeostasis in roots and nodules.