The NiCoFe-based alloys are potential high-performing bifunctional electrocatalysts towards overall alkaline water splitting, though it is still challenging to achieve this goal. Herein, the NiCoFe/CeO2-x heterostructure with abundant interfacial oxygen vacancies is constructed through in-situ hydrogenation. The strong metal-support interaction favors the formation of the medium-entropy NiCoFe ternary alloy and the interfacial oxygen vacancies, while the introduction of the cobalt highly increases the electrochemically active surface area (ECSA). The ECSA of the NiCoFe/CeO2-x is more than 3 times those of the NiCoFe, NiFe/CeO2-x, NiCo/CeO2-x and CoFe/CeO2-x. Therefore, the NiCoFe/CeO2-x shows high catalytic performance towards both hydrogen evolution reaction and oxygen evolution reaction with a small overpotential of 42 and 238 mV at 10 mA cm−2 in 1 M KOH, respectively. More importantly, the NiCoFe/CeO2-x heterostructure with optimal elemental composition demonstrates excellent catalytic performance towards overall water splitting, exhibiting a small cell voltage of 1.52 V at 10 mA cm−2 without iR compensation. In addition, it shows good working stability in the overall water splitting at 100 mA cm−2 during a period of >10 h.