An efficient magnetic polymer-based nanomaterial was prepared in three main steps including synthesis of polyacrylonitrile (PAN), modification of PAN with melamine, and magnetization of the PAN@melamine compound by in situ construction of Fe 3 O 4 MNPs. The novel PAN@melamine/Fe 3 O 4 organometallic nanocomposite was well characterized by various techniques such as Fourier transform infrared (FT-IR) spectroscopy, energy dispersive X-ray (EDX) spectroscopy, thermogravimetric analysis (TGA), field emission scanning electron microscope (FESEM), transmission electron microscopy (TEM), X-ray diffraction (XRD) pattern, and vibrating sample magnetometer (VSM) curve. Afterward, the fabricated nanocomposite was used as a heterogeneous catalyst in two multicomponent reactions (MCRs) for the synthesis of biologically active dihydropyrano[2,3-c]pyrazole and 2-amino-3-cyano 4H-pyran derivatives. The corresponding products were obtained in excellent yields without a complicated work-up process. Besides, the prepared nanocatalyst could be recycled and reused at least five consecutive runs in both MCRs without a considerable decline in its catalytic activity.