In the eighties, when multiple countries developed multi-purpose locomotives with three-phase traction motors, also the Italian FS approached Ansaldo to develop such a locomotive. The first prototype, numbered E.402.000, was built in 1985. Even though it operated under only 3,000 V DC, it developed an output of 6,000 kW (8,050 hp) with only four axles. Now there was a single locomotive that could haul intercity trains at 220 km/h (137 mph), but had sufficient pulling power for heavy freight trains.
Due to the good performances of the prototype, four pre-production locomotives were built in 1988. Series production of the E.402A started in 1994 and by 1996, 40 had been completed. These had a more streamlined design and also the prototypes and pre-production locomotives were rebuilt. Around the turn of the millenium the FS was divided and all E.402A came to the intercity division. So they nearly never hauled freight trains as planned, but almost always intercity trains.
In their original form, these locomotives were used until 2019. After this, all were rebuilt into the E.401 by modernizing the electric part and removing one cab for use on push-pull trains, similar to the E.464. The direct successor of the E.402A is the E.402B that can also operate under 25 kV AC.