Britannica
Sources used in this answer
Why do parallel wires with currents in the same direction attract?
Created from Britannica articles
using AI.
AI can make mistakes, so verify using Britannica articles.
electromagnet
Figure 1: Elements of a solenoid
Parallel wires carrying currents in the same direction attract each other because of the interaction between each wire's current and the magnetic field produced by the other.12
According to Ampère’s law, an electric current creates a magnetic field that circles the wire. When two parallel wires carry current in the same direction, the right-hand rule dictates the orientation of these fields. Each wire is effectively placed within the magnetic field generated by the other. Because the currents are aligned, the resulting Lorentz force exerted on the moving charges within each wire acts in a direction that pulls the wires toward one another. Conversely, if the currents flow in opposite directions, the resulting force is repulsive.3214