Developing high-performance electrocatalysts toward hydrogen evolution reaction is important for clean and sustainable hydrogen energy, yet still challenging. Herein, we report a single-atom strategy to construct excellent metal-organic frameworks (MOFs) hydrogen evolution reaction (HER) electrocatalyst (NiRu0.13-BDC, BDC: terephthalic acid) by introducing atomically dispersed Ru. Significantly, the obtained NiRu0.13-BDC exhibits outstanding HER activity in all pH, especially with a low overpotential of only 36 mV at a current density of 10 mA cm-2 in 1 M phosphate buffered saline (PBS) solution, which is comparable to commercial Pt/C. X-ray absorption fine structures and the density functional theory calculations reveal that introducing Ru single-atom can modulate electronic structure of metal center in the MOF, leading to the optimization of binding strength for H2O and H*, and the enhancement of HER performance. This work establishes single-atom strategy as an efficient approach to modulate electronic structure of MOFs for catalyst design.