Environment friendly separation of optimistic and unfavorable prices is important for creating high-performance nanogenerators. On this article, we describe a way that was not beforehand demonstrated to separate prices which permits us to manufacture a magnetic power harvesting system. The magnetic subject induces the migration of the cell magnetic counterions (Dy(NO3)4−) which establishes anion gradients inside a layer of polyionic liquid micropores (PLM). The PLM is covalently cross-linked on which the optimistic prices are mounted on the matrix, that’s, motionless. In a tool with a construction of Au/dielectric//mag-PLM//dielectric/Au, the cost gradient is subsequently reworked into the output voltage via electrostatic induction. Eradicating the magnetic subject results in the backflow of magnetic anions which produces a voltage with the same magnitude however reversed polarity. The parameters in fabricating the magnetic PLM comparable to photoinitiator focus, UV irradiation time, water therapy time, and temperature are discovered to dramatically affect the scale of micropores and the efficient focus of magnetic anions. Below optimized situations, an output voltage with an amplitude of roughly 4 V is lastly achieved. We anticipate this new technique may discover sensible functions in additional bettering the output efficiency.