This work deals with the synthesis and characterization of one-dimensional (1D) imidazole-containing etidronates, [M2(ETID)(Im)3]·nH2O (M = Co2+ and Ni2+; n = 0, 1, 3) and Zn2(ETID)2(H2O)2](Im)2, as well as the corresponding Co2+/Ni2+ solid solutions. Depending on the water content, metal ions in the isostructural Co2+ and Ni2+ derivatives are octahedrally coordinated (n = 3) or consist of octahedral together with dimeric trigonal bipyramidal (n = 1) or square pyramidal (n = 0) environments. The imidazole molecule acts as a ligand (Co2+, Ni2+ derivatives) or charge-compensating protonated species (Zn2+ derivative). For the latter, the proton conductivity is determined to be ∼6 × 10−4 S·cm−1 at 80 °C and 95% relative humidity (RH). By pyrolyzing in 5%H2−Ar at 700−850 °C, core−shell electrocatalysts consisting of Co2+-, Ni2+-phosphides or Co2+/Ni2+-phosphide solid solution particles embedded in a N-doped carbon graphitic matrix are obtained, which exhibit improved catalytic performances compared to the non-N-doped carbon materials. Co2+ phosphides consist of CoP and Co2P in variable proportions according to the used precursor and pyrolytic conditions. However, the Ni2+ phosphide is composed of Ni2P exclusively at high temperatures. Exploration of the electrochemical activity of these metal phosphides toward the OER, ORR, and HER reactions reveals that the anhydrous Co2(ETID)(Im)3 pyrolyzed at 800 °C (CoP/Co2P = 80/20 wt %) is the most active trifunctional electrocatalyst, with good integrated capabilities as an anode for overall water splitting (cell voltage of 1.61 V) and potential application in Zn−air batteries. This solid also displays a moderate activity for the HER with an overpotential of 156 mV and a Tafel slope of 79.7 mV·dec−1 in 0.5 M H2SO4. Ni2+- and Co2+/Ni2+-phosphide solid solutions show lower electrochemical performances, which are correlated with the formation of less active crystalline phases.