Dehydrogenases are widely employed as biocatalysts for the production of optically pure chemicals under mild conditions. Most dehydrogenases are nicotinamide cofactor (NADPH or NADH)-dependent oxidoreductases. 7β-Hydroxysteroid dehydrogenase (7β-HSDH) is a key enzyme for the biochemical synthesis of ursodeoxycholic acid (UDCA). To date, all reported 7β-HSDHs are strictly NADPH-dependent enzymes. However, compared with NADPH, NADH is much more economical, making it the preferential cofactor for synthetic applications of dehydrogenases. In this work, a recombinant 7β-HSDH originating from Ruminococcus torques was rationally engineered to alter its cofactor dependence using a strategy referred to as Cofactor Specificity Reversal: Small-and-Smart Library Design (CSR-SaSLiD), which is based on structural information and conservative sequence alignment. We rationally designed a small-and-smart library containing only five mutants that enabled the quick identification of target variants. Compared with the wild type, the resultant mutant, G39D, showed a 953 000-fold switch in cofactor specificity from NADPH to NADH, and another mutant, G39D/T17A, resulted in 223-fold enhanced activity with NADH. The structural mechanism regarding the effect of mutation on the reversal of cofactor preference and improvement of catalytic activity was elucidated with the aid of molecular dynamics simulation. Furthermore, it was confirmed that the CSR-SaSLiD strategy can be extended to other 7β-HSDHs. This work provides an efficient approach to altering cofactor preference and subsequently recovering the enzymatic activity of dehydrogenases for cost-effective biotechnical applications.