The Magnetic Field Around a Current-Carrying Wire is one of the most important ideas in electromagnetism. Whenever electric current flows through a conductor, it produces a magnetic field around the conductor. This relationship between electricity and magnetism is used in motors, generators, electromagnets, transformers, speakers, and many other electrical devices.
For a long, straight wire carrying current, the magnetic field has a simple mathematical expression:
This equation tells us how the magnetic field depends on the current flowing through the wire and the distance from the wire.
The magnetic field becomes stronger when the current increases and weaker when the observation point moves farther away from the wire. The direction of the field can be determined using the right-hand rule.
What Is a Magnetic Field?

A magnetic field is a region around a magnet, electric current, or changing electric field where magnetic forces can act.
Magnetic fields are represented by the symbol:
The SI unit of magnetic field is the tesla:
A magnetic field is a vector quantity, meaning it has both magnitude and direction.
When electric current flows through a straight wire, the magnetic field does not point along the wire. Instead, the field forms circular paths around the wire.
This circular pattern is one of the key features of the Magnetic Field Around a Current-Carrying Wire.
Magnetic Field Around a Current-Carrying Wire
A current-carrying wire produces a magnetic field in the space surrounding it.
For a long, straight wire, the magnetic field lines form concentric circles centered on the wire.
The wire can be imagined as passing through the center of these circles.
If the current flows upward through the wire, the magnetic field circles around it in a particular direction. If the direction of current is reversed, the direction of the magnetic field also reverses.
The strength of the field depends mainly on two factors:
- The current through the wire
- The distance from the wire
For a long straight wire, the relationship is:
and:
Combining these relationships gives the standard formula.
Magnetic Field Formula for a Straight Wire
The magnetic field at a distance from a long, straight current-carrying wire is:
where:
- is the magnetic field.
- is the permeability of free space.
- is the current in the wire.
- is the perpendicular distance from the wire.
The permeability of free space is:
Therefore, the formula can also be written as:
This equation applies to an idealized infinitely long straight wire or a wire long enough that end effects can be neglected.
You May Like to Read: 10+ Powerful Friction Force Explained Formulas & Examples
Understanding the Formula
The equation:
contains several important physical relationships.
Magnetic Field and Current
The magnetic field is directly proportional to the current:
If the current doubles, the magnetic field doubles, assuming the distance remains unchanged.
For example, if a wire produces a field of 2 mT at a certain distance while carrying 3 A, increasing the current to 6 A would produce a field of 4 mT at the same distance.
Magnetic Field and Distance
The magnetic field is inversely proportional to the distance:
If the distance from the wire doubles, the magnetic field becomes half as large.
Unlike an electric point charge, whose field decreases according to an inverse-square relationship, the field around a long straight current-carrying wire decreases as .
Direction of the Magnetic Field
The direction of the Magnetic Field Around a Current-Carrying Wire can be determined using the right-hand rule.
Right-Hand Rule
Imagine holding the wire with your right hand.
Point your right thumb in the direction of conventional current.
Your curled fingers show the direction of the magnetic field around the wire.
For example:
If current flows upward, your fingers curl around the wire in one direction.
If current flows downward, the field direction reverses.
This rule provides a quick way to determine the magnetic field direction without performing a calculation.
Why Do Magnetic Field Lines Form Circles?
For a long straight wire, the magnetic field has cylindrical symmetry around the wire.
There is no preferred direction around the wire, so the field naturally forms circular paths centered on the conductor.
At a given distance from the wire, the magnetic field has the same magnitude at every point, assuming an ideal infinitely long wire and uniform current.
Therefore, the field lines are concentric circles.
As the distance from the wire increases, the circles become larger and the field strength decreases.
You May Like to Read: Adswynk Com Review 2026: Powerful Features, Safety & Hidden Risks Revealed
Deriving the Magnetic Field Formula Using Ampère’s Law
The formula for a long straight wire can be derived using Ampère’s law.
Ampère’s law is:
For a long straight wire, choose a circular Amperian loop of radius centered on the wire.
Because of the symmetry, the magnetic field has the same magnitude everywhere on the circular path.
Therefore:
The circumference of the circle is:
so:
Rearranging:
This derivation explains why the circumference appears in the denominator.
Example: Calculating Magnetic Field
A long straight wire carries a current of:
Find the magnetic field at a distance of:
Using:
substitute:
Cancel :
Therefore:
or:
Example: Finding Current From Magnetic Field
Suppose the magnetic field near a long straight wire is:
at a distance of:
Find the current.
Start with:
Rearrange:
Substitute the values:
Cancel terms appropriately:
Therefore:
Example: Effect of Distance
A wire produces a magnetic field of:
at a distance of:
What is the field at:
The distance has doubled.
Because:
the magnetic field becomes half as large:
This illustrates the inverse relationship between magnetic field and distance.
Magnetic Field Lines Around a Wire
Magnetic field lines provide a visual representation of the field.
Around a long straight wire:
- The field lines form circles.
- The wire lies at the center of the circles.
- The direction is determined by the right-hand rule.
- The field is stronger closer to the wire.
- The field becomes weaker farther away.
The spacing of field lines is often used as a qualitative indication of field strength. Closer lines represent a stronger field, while more widely spaced lines represent a weaker field.
Superposition of Magnetic Fields
If more than one current-carrying wire is present, each wire produces its own magnetic field.
The total magnetic field is the vector sum of the individual fields:
This is called the principle of superposition.
The directions of the individual fields must be considered before adding them.
Two magnetic fields can reinforce each other or partially or completely cancel depending on their directions.
Two Parallel Current-Carrying Wires
When two parallel wires carry current, each wire produces a magnetic field around itself.
This creates a magnetic force between the wires.
Two parallel wires carrying currents in the same direction attract one another.
Two parallel wires carrying currents in opposite directions repel one another.
The force per unit length between two long parallel wires is:
where:
- is the force per unit length.
- and are the currents.
- is the separation between the wires.
This relationship is another important application of the Magnetic Field Around a Current-Carrying Wire.
You May Like to Read: Pixelspinx Com Review 2026: Is It Safe, Legit or a Scam?
Magnetic Force on a Current-Carrying Wire
A current-carrying wire placed inside an external magnetic field can experience a magnetic force.
The force is:
For a wire perpendicular to the magnetic field:
where:
- is the current.
- is the length of wire in the field.
- is the magnetic field.
The direction of the force can be determined using a suitable right-hand rule for the cross product.
This force is the basic operating principle of electric motors.
Magnetic Field of a Current Loop
A current flowing through a circular loop produces a magnetic field that is stronger near the center of the loop.
At the center of a single circular loop of radius :
The field direction can again be determined using the right-hand rule.
Curl your fingers in the direction of conventional current around the loop. Your thumb points in the direction of the magnetic field through the center.
The field of a current loop resembles the field of a small bar magnet.
Magnetic Field Inside a Solenoid
A solenoid is a long coil of wire containing many closely spaced turns.
When current flows through the coil, it creates a relatively strong and nearly uniform magnetic field inside the central region of a sufficiently long solenoid.
The magnetic field is approximately:
where:
- is the number of turns per unit length.
- is the current.
If the solenoid has turns over a length , then:
and therefore:
A magnetic material inside the solenoid can increase the field strength further.
Applications of the Magnetic Field Around a Current-Carrying Wire
The relationship between electric current and magnetic fields is used in many technologies.
Electric Motors
Motors use magnetic forces acting on current-carrying wires to produce rotational motion.
Electromagnets
A coil carrying current can create a strong magnetic field and can be used to make an electromagnet.
Generators
Generators use changing magnetic fields and conductors to produce electrical energy.
Transformers
Transformers use changing currents and magnetic fields in coils to transfer electrical energy between circuits.
Speakers
Speakers use the interaction between current and magnetic fields to create mechanical vibrations that produce sound.
Relays and Solenoids
Electromagnetic relays and solenoids use current-generated magnetic fields to create controlled mechanical movement.
Difference Between Electric Field and Magnetic Field
Electric and magnetic fields are related, but they are not the same.
An electric field is associated with electric charges and exerts forces on charges.
A magnetic field is produced by moving charges, electric currents, magnets, and changing electric fields.
The electric field is measured in:
or:
The magnetic field is measured in:
A stationary charge does not experience a magnetic force simply because it is in a magnetic field. Magnetic force on a particle depends on its velocity.
The magnetic force on a moving charge is:
Biot-Savart Law
The Magnetic Field Around a Current-Carrying Wire can also be calculated using the Biot-Savart law.
The differential form is:
The Biot-Savart law is more general than the simple straight-wire equation.
For complicated current distributions, the contribution from small sections of the conductor can be calculated and integrated.
For a long straight wire, the result simplifies to:
Ampère’s Law and the Straight Wire
Ampère’s law provides a particularly convenient method for finding the magnetic field when the system has sufficient symmetry.
For a long straight current-carrying wire:
The circular symmetry allows the field to be treated as constant along a circular path of radius .
This leads directly to:
and therefore:
This is why Ampère’s law is commonly introduced alongside the field of a long straight conductor.
You May Like to Read: Whatutalkingboutwillis Gift Guide: 15+ Brilliant Ideas to Avoid Bad Gifts
Effect of Reversing the Current
Changing the magnitude of current changes the strength of the magnetic field.
Reversing the current does not change the magnitude, assuming the current’s magnitude remains the same. Instead, it reverses the direction of the magnetic field.
For example, if:
is changed to:
the field direction reverses.
This follows directly from the right-hand rule.
Effect of Increasing the Current
Because:
increasing the current increases the magnetic field proportionally.
If the current changes from A to A, it becomes three times larger.
Therefore, at the same distance:
This is one of the simplest proportional relationships in the formula.
Effect of Increasing the Distance
Because:
the field decreases as distance increases.
If the distance from the wire becomes four times larger:
then:
This explains why the magnetic field is strongest close to the conductor.
Magnetic Field Near a Real Wire
The formula:
is an ideal model for a long straight wire.
A real wire has a finite length, so near the ends, the magnetic field can differ from the simple infinite-wire result.
For points sufficiently far from the ends compared with the distance from the wire, the long-wire approximation is often a good model.
For finite wires, more general forms based on the Biot-Savart law may be needed.
Magnetic Field Inside a Current-Carrying Wire
If the wire has a finite radius and carries current uniformly throughout its cross-section, the magnetic field inside the wire varies with distance from the center.
For a cylindrical wire of radius carrying uniformly distributed current , at a point inside the conductor where , Ampère’s law gives:
Since the enclosed current is proportional to the enclosed area:
Therefore:
This means that the magnetic field increases linearly with distance from the center inside the idealized wire.
Outside the wire, the field follows:
Common Mistakes When Calculating Magnetic Field
One common mistake is using the wrong distance. The in the formula is the perpendicular distance from the wire to the point where the field is being calculated.
Another mistake is forgetting that distance must be in meters when using SI units.
For example:
Students may also accidentally use an inverse-square relationship:
for a long straight wire. The correct relationship is:
Another common error is using electron flow direction instead of conventional current direction when applying the standard right-hand rule. Conventional current is defined as the direction of positive charge flow.
Finally, remember that magnetic field is a vector, so direction matters when several magnetic fields are combined.
You May Like to Read: Wave Interference: Amazing Types, Examples & Uses 2026
Magnetic Field Around a Current-Carrying Wire Formula Summary
For a long straight current-carrying wire:
Permeability of free space:
The magnetic field is directly proportional to current:
and inversely proportional to distance:
For a circular current loop at the center:
For a long solenoid:
The force on a current-carrying wire in a magnetic field is:
For two long parallel wires:
These equations cover many of the most common introductory magnetism problems.
Frequently Asked Questions
What is the Magnetic Field Around a Current-Carrying Wire?
A current-carrying wire produces a magnetic field that forms circular paths around the wire. For a long straight wire, the field strength depends on the current and the distance from the wire.
What is the formula for the magnetic field around a straight wire?
The formula is:
where is the current and is the perpendicular distance from the wire.
What happens to the magnetic field when current increases?
The magnetic field increases in direct proportion to the current. Doubling the current doubles the magnetic field at the same distance.
What happens to the magnetic field when distance increases?
For a long straight wire, the magnetic field decreases inversely with distance. Doubling the distance reduces the magnetic field to half its original value.
How do you find the direction of the magnetic field?
Use the right-hand rule. Point your right thumb in the direction of conventional current, and your curled fingers show the direction of the magnetic field.
Conclusion
The Magnetic Field Around a Current-Carrying Wire demonstrates one of the fundamental connections between electricity and magnetism. Whenever current flows through a conductor, it produces a magnetic field around it.
For a long straight wire, the field is given by:
This equation shows that magnetic field strength increases with current and decreases as the distance from the wire increases. The field forms concentric circles around the wire, and the right-hand rule provides a simple way to determine its direction.
The same principles lead to the behavior of current loops, solenoids, electromagnets, electric motors, and the force between parallel current-carrying wires.
Once you understand the relationship between current, distance, magnetic field strength, and field direction, you have a strong foundation for studying more advanced topics in electromagnetism.
