One of the recent advances for the beyond complementary metal-oxide semiconductor (CMOS) area is nano-magnetic logic (NML). Many researchers are developing a keen interest in the areas of circuit designing, area optimization and its application in storing the data. Because of its inherent magnetic nature, it can be used to design any magnetic circuit. When compared to the CMOS technology NML logic has potential advantages in terms of non-volatile, low power and radiation in hard. In this paper, we have proposed and implemented a 4-bit squarer circuit using the perpendicular NML (pNML). Squarer design is implemented in MagCAD tool, which embeds design rules, physical models and technological parameters. A register-transfer-level of (VHDL) of the circuit is automatically extracted by MagCAD. The extracted model can be simulated with fast HDL-simulators; this makes it possible to verify the behavior and extract the performance of the designed circuit. This nano-magnetic logic technology is alternative to CMOS technology, which is non-volatile in nature with reduced power consumption. © 2020, Springer Nature Singapore Pte Ltd.