The hydrogen evolution reaction (HER) is a crucial step in alkaline water electrolysis, but suffers from sluggish reaction kinetics, which calls for the development of active and robust catalysts for the highly efficient production of high-purity hydrogen. Here, we report hierarchical nanoporous (NP) transition-metal (TM = Fe, Co)-doped Pt3Al intermetallic compounds, which are composed of surface alloys of Pt and TMs with in situ self-grown TM hydroxides in an alkaline environment, NP (Pt1−xTMx)3Al/Pt-TM(OH), as highly efficient bifunctional catalysts for the HER. By virtue of the constituent Co(OH)2 having moderate hydroxyl adsorption to accelerate water dissociation and the Pt atoms facilitating the adsorption/desorption of reactive hydrogen intermediates, the NP (Pt1−xCox)3Al/Pt-Co(OH)2 exhibits superior HER activity in 0.1 M KOH, with a low Tafel slope of 48 mV dec−1 and an overpotential of ∼43 mV at 10 mA cm−2, as well as exceptional durability due to its unique nanoporous structure with stable intermetallic bonds. These electrocatalytic properties outperform state-of-the-art Pt-based catalysts, suggesting that multi-site design is suitable for producing highly efficient catalysts towards the HER in alkaline environments.