Solenoid Magnetic Field Calculator

The Solenoid Magnetic Field Calculator helps you find the magnetic field inside a long solenoid.

Clear
Field inside the solenoid31.4159 mT314.1593 gauss — µ₀µ_r n I with 2,500 turns a metre
Turns per metre2,500only the turn DENSITY matters inside a long solenoid, not the total turns or the radius
Inductance3.0843 mHµN²A ÷ l — this one does depend on the total turns, and on the square of them
Energy stored at this current154.2126 mJ
Field at four times the turns125.6637 mTfour times the field, but SIXTEEN times the inductance
Length-to-diameter ratio4below about 5 the long-solenoid formula overstates the field, because the ends leak
Permeability used1.2566 µH/mµ₀, the vacuum value. Since 2019 this is a MEASURED quantity, not exactly 4π×10⁻⁷

The formula

wire B = µ₀I ÷ 2πr; solenoid B = µ₀nI; L = µ₀N²A ÷ l

Line sources fall off more slowly

A long straight wire's field falls as 1/r, not as an inverse square. That is not an exception to anything — it follows from the source being a line rather than a point, and integrating the contributions along it. A point source in three dimensions gives 1/r²; a line gives 1/r; an infinite sheet gives a field that does not fall off at all.

Inside a long solenoid the field depends only on the turn density and the current — not on the radius, and not on the total number of turns. Two solenoids of very different diameters with the same turns per metre produce identical interior fields. Inductance is different: it goes as the square of the total turns and with the cross-sectional area, so a fat coil stores far more energy at the same field.

The formula assumes a long solenoid. Below a length-to-diameter ratio of about five the ends leak appreciably and the real field is lower than calculated.

An iron core multiplies the field by its relative permeability, which can reach several thousand — but only until the core saturates, typically around 1.5 to 2 tesla, beyond which further current buys almost nothing. Note that µ₀ has been a measured quantity since the 2019 SI redefinition; it is no longer exactly 4π×10⁻⁷.