Magnetic CoFe alloy nanowires were alternating current (ac)-pulse electrodeposited into the nanopores of hard anodized aluminum oxide templates. The effect of nanowires lengths on the magnetostatic interactions was investigated using first-order reversal-curve (FORC) method. FORC diagrams obtained from nanowire arrays with different lengths show drastic improvement in magnetic properties with decreasing the nanowires length. The coercivity reaches 995 Oe from initially 790 Oe. Also, the squareness enhances from 0.62 to 0.92, showing the decrease in magnetostatic interactions between the nanowires. FORC diagrams prove the decrease in magnetostatic interactions in nanowires with shorter lengths. With decreasing the nanowires length, the spread of distribution in the Hu-direction decreases. It varies from 1600 to 900 Oe when length decreases from 27 to 8 μm. FORC diagrams also reveal formation of nanowire arrays with dominant interacting single domain (SD).