Abstract In this study, a new type of magnetite nanocomposite with a core–shell structure was synthesized using Fe 3 O 4 nanoparticles as a core and polyaniline (PANI) as a shell. For this propose, the surface of Fe 3 O 4 was chemically modified with hexamethylenediisocyanate (HMDI) to improve its compatibility and interphase interaction with the polymeric matrix. Thereafter, the PANI was reacted with modified Fe 3 O 4 to anchor them to PANI by covalent bands which acted as a shell. In the second step, the poly (maleic acid‐ co ‐acrylic acid) (P(MAc‐ co ‐AA)) as polymeric dopant for the PANI was synthesized. Finally, the PANI anchored to Fe 3 O 4 was immersed in an aqueous solution of poly (maleic anhydride‐ co ‐acrylic acid) to form Fe 3 O 4 @PANI@P(MAc‐ co ‐AA) as a final composition of magnetite nanocomposite. The structural, morphological, thermal, magnetic, and electrochemical properties of the products were characterized by FTIR, H‐NMR, UV‐Vis, XRD, SEM, TEM, TGA, VSM, and CV analysis.