The successful precision measurement of the rate of muon capture on a proton by the MuCap Collaboration allows for a stringent test of the current theoretical understanding of this process. Chiral perturbation theory, which is a low-energy effective field theory that preserves the symmetries and the pattern of symmetry breaking in the underlying theory of QCD, offers a systematic framework for describing $mu p$ capture and provides a basic test of QCD at the hadronic level. We describe how this effective theory with no free parameters reproduces the measured capture rate. A recent study has addressed new sources of uncertainties that were not considered in the previous works, and we review to what extent these uncertainties are now under control. Finally, the rationale for studying muon capture on the deuteron and some recent theoretical developments regarding this process are discussed.