The construction of doped molecular clusters is an intriguing way to perform bimetallic doping for electrocatalysts. However, efficiently harnessing the benefits of a doping strategy and alloy engineering to create a nanostructure for electrocatalytic application at the molecular level has consistently posed a challenge. Here we propose an in situ reconstruction strategy aimed at producing an alloy nanostructure through a pyrolysis process, originating from bowknot-like heterometallic clusters. The Schiff base, denoted as ligand L1 (o-vanillin ethylenediamine), was introduced as a precursor to coordinate Fe and Co metals, thereby yielding a heteronuclear metal cluster [(FeCo)(L1)2O]CH3CN. Subsequently, a comprehensive investigation of the in situ reconstruction process [(FeCo)(L1)2O](CH3CN) → [(FeCo)(L1)2O] → [M-O-M/M-O] [CH3+/CH3O+/H2C═N/C2H5+/C4H4+] → [FeCo/Fe3O4/Fe2O3/Co3O4][carbon layer] led to the formation of MOx/CoFe@NC-700 during the pyrolysis. This process reveals that the metals Fe and Co in the clusters undergo partly in situ evolution into FeCo alloys, resulting in the successful preparation of MOx/CoFe@NC (M = Fe, Co) nanomaterials that leverage the advantages of both doping strategies and alloy engineering. The synergistic interaction between alloy particles and metal oxides establishes active sites that contribute to the excellent oxygen evolution (OER) and hydrogen evolution (HER) catalytic behaviors. Notably, these materials exhibit outstanding OER and HER properties under alkaline conditions, with overpotentials of 191 and 88 mV for OER and HER, respectively, at 10 mA cm-2. Investigation of the in situ conversion of Schiff base bimetal clusters into alloy materials through pyrolysis offers a novel strategy for advancing electrocatalytic applications.