This paper presents the synthesis of rare-earth doped magnesium ferrite, CexMgFe2-xO4 (where x = 0, 0.05, 0.10) by using co-precipitation process. X-ray diffraction analysis revealed the phase purity of the synthesized material. Refinement of XRD data using Rietveld suggested single phase spinel cubic formation of CexMgFe2-xO4 (where x = 0, 0.05, 0.10). The crystallite size was found to be in the range of 24–29 nm, obtained by using Scherrer's formula. SEM micrographs show the spherical particles agglomerated with cubic-shaped particles. Electron dispersive spectroscopic peaks indicate the purity of the samples with the concentration of the constituent elements in the expected range. Fourier transform infrared spectra contain two intrinsic vibrational peaks (ν1 and ν2) in the characteristic region, which may be attributed to the presence of tetrahedral group (A-site) and octahedral group at B-site in the ferrite material. Raman spectral analysis further validates the results obtained from FTIR and XRD peak analysis. The presence of well-defined polarization loops in PE loop analysis reflects the ferroelectric behavior of the synthesized samples. The ferroelectric behavior increases with an increase in Ce-doping. Magnetic studies of the synthesized samples were carried out by VSM, which depict the soft magnetic behavior of both pristine and doped samples. Magnesium ferrite was doped with Ce to create a defective structure that may be used to generate hydroelectricity. These defects produced compressive strain in these materials, confirmed by Williamson-Hall (WH) plot. These defected sites, along with oxygen vacancies present in the ferrite material, lead to water dissociation on its surface. After channelizing the dissociated ions through electrodes, these Ce-based HECs generated a maximum offload current of 5.2 mA and 8.4 mA for CexMgFe2-xO4 (CMF-1) and CexMgFe2-xO4 (CMF-2) cells with open circuit voltage of 0.86 V and 0.76 V respectively.