Electromagnetism

Maxwell's Equations

Four equations that make the entire universe of light, radio, and electric current run

Maxwell's four equations bind electric and magnetic fields to charge, current, and each other — and predict that light is an electromagnetic wave traveling at exactly c. From Gauss's law to Ampère-Maxwell, they make radio, optics, electric power, and quantum electrodynamics one subject.

  • Unified byJames Clerk Maxwell, 1861–1865
  • Number of equations4 (or 2 covariant)
  • Predicted wave speedc = 1/√(μ₀ε₀)
  • ConfirmedHertz, 1887
  • Modern form∂_μ F^μν = μ₀ j^ν

Interactive visualization

Press play, or step through manually. The visualization is yours to drive — try it before reading on.

Open visualization fullscreen ↗

Watch the 60-second explainer

A condensed visual walkthrough — narrated, captioned, under a minute.

The four equations, one paragraph each

In SI units, in vacuum and in matter without polarization, Maxwell's equations take this form:

(1) Gauss's law for E:        ∇·E = ρ/ε₀
(2) Gauss's law for B:        ∇·B = 0
(3) Faraday's law:            ∇×E = −∂B/∂t
(4) Ampère-Maxwell's law:     ∇×B = μ₀J + μ₀ε₀ ∂E/∂t

Gauss's law for E says electric charge is the source of the electric field — total flux out of any closed surface equals enclosed charge divided by ε₀. Gauss's law for B says no magnetic charge exists: every magnetic-field line that enters a closed surface eventually leaves. Faraday's law says a changing magnetic flux through a loop drives an electric field around the loop — the principle of every transformer, generator, and induction motor. Ampère-Maxwell's law says both real current and changing electric flux produce circulating magnetic field; the second term is Maxwell's own addition and is what makes the equations consistent and makes electromagnetic waves possible.

The constants are ε₀ = 8.854 × 10⁻¹² F/m and μ₀ ≈ 4π × 10⁻⁷ H/m. Their product determines the speed of light: c = 1/√(μ₀ε₀) = 2.998 × 10⁸ m/s. After the 2019 SI redefinition, c is exactly 299 792 458 m/s by definition and ε₀ inherits a slight uncertainty from measurement.

The four equations, expanded

EquationWhat it saysIntegral formSourceConsequence
Gauss's law for E (∇·E = ρ/ε₀)Charge produces electric field∮E·dA = Q_enc/ε₀Electric charge ρCoulomb's law (1/r² fall-off in 3D)
Gauss's law for B (∇·B = 0)No magnetic monopoles∮B·dA = 0None (constraint)B field lines always close
Faraday's law (∇×E = −∂B/∂t)Changing B induces E∮E·dl = −dΦ_B/dtTime-varying BGenerators, transformers, induction
Ampère-Maxwell (∇×B = μ₀J + μ₀ε₀ ∂E/∂t)Current and changing E induce B∮B·dl = μ₀(I + ε₀ dΦ_E/dt)Current J + changing EElectromagnetic waves at c
Charge conservation (corollary)∂ρ/∂t + ∇·J = 0d/dt ∫ρ dV = −∮J·dAImplied by (1) and (4)Charge cannot vanish or appear
Lorentz force (auxiliary)F = q(E + v×B)(integrated along path)EM fieldsParticle motion in EM fields

The Lorentz force law is independent of Maxwell's equations — they describe how charges and currents produce fields; the Lorentz force describes how fields push charges. Together they form the complete classical theory of electromagnetism.

Worked derivation: light is an electromagnetic wave

The decisive consequence of Maxwell's equations is that they predict transverse waves at speed c. In a vacuum (ρ = 0, J = 0), take the curl of Faraday's law:

∇×(∇×E) = ∇×(−∂B/∂t) = −∂(∇×B)/∂t

Use the vector identity ∇×(∇×E) = ∇(∇·E) − ∇²E. Since ρ = 0, ∇·E = 0, so the first term vanishes. Substitute Ampère-Maxwell with J = 0:

−∇²E = −∂/∂t (μ₀ε₀ ∂E/∂t) = −μ₀ε₀ ∂²E/∂t²

which gives

∇²E = μ₀ε₀ ∂²E/∂t²

This is the wave equation with phase velocity v = 1/√(μ₀ε₀). Plug in the 1865 measured values of μ₀ = 4π·10⁻⁷ and ε₀ = 8.854·10⁻¹²: 1/√(μ₀ε₀) ≈ 2.998 × 10⁸ m/s. Maxwell compared this to Fizeau's 1849 measurement of the speed of light (3.13 × 10⁸ m/s) and concluded "this velocity is so nearly that of light, that it seems we have strong reason to conclude that light itself is an electromagnetic disturbance." Heinrich Hertz confirmed the existence of radio-frequency electromagnetic waves in 1887, two decades after Maxwell's prediction.

The same calculation for B gives ∇²B = μ₀ε₀ ∂²B/∂t². Plane-wave solutions take the form E(r, t) = E₀ cos(k·r − ωt) ê, with ω = ck and B perpendicular to both k and E with magnitude B₀ = E₀/c. Light is a self-sustaining oscillation in which the changing electric field generates the changing magnetic field which regenerates the changing electric field, all moving at c.

Why the displacement current matters

Consider a parallel-plate capacitor being charged by a current I flowing through the wires. Pick an Amperian loop encircling the wire on one side of the capacitor, then a different loop encircling the gap between the plates. With pre-Maxwell Ampère's law (∇×B = μ₀J), the first loop gives B from the wire current; the second loop gives B = 0 because no current flows through the gap. The same loop gives two different answers — a contradiction.

Maxwell's fix: the changing electric field between the plates contributes ε₀ ∂E/∂t. As the capacitor charges, E between the plates rises and ε₀ ∂E/∂t equals exactly J in magnitude. Both loops now agree on the encircling magnetic field. The displacement current restores consistency and is essential for charge conservation: taking the divergence of Ampère-Maxwell and using Gauss's law gives ∂ρ/∂t + ∇·J = 0, the continuity equation.

For a 1 μF capacitor charged through a 1 kΩ resistor at 5 V, the time constant is τ = RC = 1 ms and the displacement-current density between 1 cm² plates separated by 1 mm peaks at JD = ε₀ (V/d)/τ ≈ ε₀·5000/0.001 = 4.4 × 10⁻⁵ A/m². It is a small number, but it is enough to make the magnetic-field calculation self-consistent and is responsible for radio.

Where Maxwell's equations show up

  • The 5G/6G wireless spectrum. 5G NR uses 600 MHz to 71 GHz; 6G research extends to 300 GHz. Antenna design, beamforming, and propagation losses are all Maxwell's-equation simulations in commercial software (HFSS, CST, FEKO). A typical 5G beamforming array of 64 patch antennas at 28 GHz is designed by solving Maxwell's equations on ~10⁸ tetrahedral elements over 100 GB of mesh.
  • The Square Kilometre Array (SKA-Low) at 50–350 MHz. 131,072 dipole antennas in Western Australia (first phase complete 2027) collectively form a virtual aperture by coherently combining electromagnetic-wave amplitudes. Every astronomical signal is a Maxwell-equation solution that propagates from a redshift-z source through cosmological distances and atmospheric ionosphere before being recorded.
  • The ITER tokamak's plasma confinement. ITER's 6.2 m magnetic axis and 5.3 T toroidal field confine 150-million-K plasma for > 400-second pulses. The plasma's evolution is governed by magnetohydrodynamic equations — Maxwell's equations coupled to fluid dynamics. ITER's first plasma is scheduled for 2034 (delayed from 2025).
  • NIST's optical clocks at 10⁻¹⁹ relative precision. The strontium and aluminum-ion atomic clocks at NIST and JILA exploit narrow optical transitions of trapped ions/atoms. The trap fields are designed by solving Maxwell's equations to nanovolt precision; magnetic-field gradients across the trap volume ≪ 1 nT/mm are the limit on systematic error budget.
  • MRI scanners at 1.5–7 T. A clinical 3 T MRI generates 64 MHz Larmor-frequency RF pulses (at 42.58 MHz/T for hydrogen) and gradient fields ~50 mT/m for spatial encoding. Image reconstruction inverts the Maxwell-equation Fourier relationship between k-space and image space; 4D phase-contrast cardiac MRI integrates Maxwell-equation simulations of RF coil response across a 0.5 mm voxel grid.

The covariant form: one tensor equation

Special relativity makes Maxwell's equations far more compact. Define the antisymmetric field-strength tensor Fμν = ∂μAν − ∂νAμ, where Aμ = (φ/c, A) is the 4-potential. Its components are

F^0i = E_i / c        F^ij = −ε^ijk B_k

The four Maxwell equations become

∂_μ F^μν = μ₀ j^ν       (Gauss's law and Ampère-Maxwell)
∂_μ F̃^μν = 0             (Gauss's law for B and Faraday)

where F̃μν = ½εμνρσFρσ is the dual tensor and jμ = (cρ, J). Two equations replace four. Lorentz invariance is manifest: under a boost, Fμν transforms as a (2,0)-tensor and the equations keep the same form. The two Lorentz invariants of the field are FμνFμν = 2(B² − E²/c²) and Fμνμν = −4 E·B/c. Every observer agrees on these two numbers regardless of motion.

The QED Lagrangian density is ℒ = −¼ FμνFμν + ψ̄(iγμDμ − m)ψ with Dμ = ∂μ + ieAμ. Demanding U(1) gauge invariance — Aμ → Aμ + ∂μα(x), ψ → e−iα(x)ψ — uniquely fixes the form of the interaction. Maxwell's equations are the prototypical gauge theory; the rest of the Standard Model (electroweak SU(2)×U(1), QCD SU(3)) generalizes the same template to non-abelian groups.

Boundary conditions at interfaces

Across a boundary between two materials with different ε and μ, Maxwell's equations imply specific matching conditions:

  • The tangential component of E is continuous (from ∇×E = −∂B/∂t).
  • The normal component of D = εE jumps by the surface charge σ.
  • The tangential component of H = B/μ jumps by the surface current K.
  • The normal component of B is continuous (from ∇·B = 0).

These four conditions are what determine reflection, refraction, total internal reflection, and the Fresnel coefficients. For light hitting glass at normal incidence with n1 = 1.0 (air) and n2 = 1.5 (crown glass), the reflection coefficient is r = (n2−n1)/(n2+n1) = 0.2 and the intensity reflection R = r² = 0.04 — the 4% reflection per glass surface that makes anti-reflection coatings necessary in any precision optic.

Variants and extensions

  • Maxwell in matter. In dielectric and magnetic media, replace E by D = εE and B by H = B/μ; the equations look the same but with effective constants depending on the material. Polarization P and magnetization M are the bookkeeping for bound charges and currents.
  • Quantum electrodynamics (QED). Promote Aμ to a quantum field. The photon is the gauge boson; vacuum fluctuations produce the Lamb shift, the anomalous magnetic moment of the electron, and Casimir forces. QED is the most precisely tested theory in physics: the electron's g − 2 is predicted to one part in 10¹².
  • Yang-Mills generalization. Replace the abelian U(1) gauge group with a non-abelian SU(N). The field-strength becomes Faμν = ∂μAaν − ∂νAaμ + g fabc Abμ Acν with extra self-interaction terms. The Standard Model SU(2)×U(1) and QCD SU(3) follow this template.
  • Magnetic monopoles (hypothetical). Introduce a magnetic charge density ρm and current Jm: ∇·B = μ₀ρm, −∇×E = ∂B/∂t + μ₀Jm. Maxwell's equations become symmetric in E ↔ B. Dirac (1931) showed that if even one monopole exists, electric charge must be quantized.
  • Curved-spacetime Maxwell. Replace ∂μ with covariant derivative ∇μ using the spacetime metric gμν. Light bends around the Sun (1.75 arcsec deflection at the limb), gravitational waves from compact binaries propagate Maxwell-like, and the cosmic microwave background photons redshift accordingly.
  • Computational electromagnetics (CEM). Numerical methods for solving Maxwell's equations in arbitrary geometries: finite-difference time-domain (FDTD, the workhorse of antenna design), method of moments (MoM, integral equations on conducting surfaces), and finite-element method (FEM, used in ANSYS HFSS and COMSOL). The 2025 state of the art handles 10¹⁰ grid cells on GPU clusters.

Common pitfalls

  • Confusing E with D and B with H in matter. The free-space versions of Maxwell's equations use E and B; the in-matter versions use D = ε₀E + P (free charges as sources) and H = B/μ₀ − M (free currents as sources). Mixing them produces wrong factors of εr and μr. Pick one convention per problem.
  • Forgetting the displacement current at high frequency. At low frequency (∂E/∂t small) you can drop the ε₀ ∂E/∂t term and Ampère's law becomes the familiar magnetostatic relation. At MHz and above the displacement current dominates; ignoring it means losing the wave-propagation behavior entirely.
  • Sign convention for Faraday's law. The minus sign is Lenz's law — induced EMF opposes the change in flux. Drop the sign and you predict that energy comes from nowhere, violating conservation. Always check your right-hand rules together with the sign.
  • Wrong gauge condition. Maxwell's equations are gauge-redundant: ∇·A and ∂φ/∂t can be any compatible choice (Coulomb gauge, Lorenz gauge, axial gauge). Once you choose a gauge, computations are valid only in that gauge. Mixing gauges or changing partway through gives nonsense.
  • Misusing the integral form when the surface is moving. The integral form of Faraday's law ∮E·dl = −dΦ/dt holds for any closed loop, but if the loop is moving you must include the motional EMF. The differential form ∇×E = −∂B/∂t is local and unambiguous; using the integral form on a moving loop without handling the motion explicitly is a common error in generator analysis.

Frequently asked questions

Why are Maxwell's equations called "Maxwell's" if Gauss, Faraday, and Ampère wrote three of them?

Because Maxwell's contribution — the displacement current term ε₀ ∂E/∂t in Ampère's law — is what made the system self-consistent and predicted electromagnetic waves. Without it, the four equations imply ∇·J = 0 (no charge can accumulate), which is wrong whenever a capacitor charges. Maxwell's 1861 addition fixed this and produced wave equations whose speed equaled the measured speed of light. The unification is Maxwell's; the individual laws were known.

What is the displacement current physically?

It is the electric field's contribution to the magnetic-field source, not a literal current of charge. When the field E in a region changes with time — for instance, between the plates of a charging capacitor where no real current flows through the gap — Maxwell showed that the changing E produces magnetic field exactly as if a real current density of magnitude ε₀ ∂E/∂t were present. The term restores charge conservation and produces electromagnetic waves; the name "displacement current" is historical.

How do Maxwell's equations imply the speed of light?

Take the curl of Faraday's law: ∇×(∇×E) = −∂(∇×B)/∂t. Use the vector identity ∇×(∇×E) = ∇(∇·E) − ∇²E = −∇²E in vacuum (∇·E = 0). Substitute Ampère-Maxwell's law (∇×B = μ₀ε₀ ∂E/∂t in vacuum) for ∇×B. The result is ∇²E = μ₀ε₀ ∂²E/∂t² — the wave equation with phase velocity c = 1/√(μ₀ε₀). Plugging in 4π·10⁻⁷ for μ₀ and 8.854·10⁻¹² for ε₀ gives c = 2.998·10⁸ m/s. Maxwell got this in 1861 and immediately concluded that light is an electromagnetic wave.

What's the difference between integral and differential forms?

Mathematically equivalent for smooth fields. The integral form (∮E·dA = Q/ε₀, etc.) is convenient for symmetric problems where you can pick a clever Gaussian surface or Amperian loop. The differential form (∇·E = ρ/ε₀, etc.) is the local statement and is what you need for fields that vary continuously in space — boundary-value problems, wave propagation, and any numerical simulation. The differential forms are derived from the integrals by Gauss's theorem and Stokes's theorem.

Are there magnetic monopoles?

Not in our universe, as far as anyone has measured. Maxwell's equations as written assume ∇·B = 0 — no magnetic charge — and this assumption agrees with every experiment. Dirac showed in 1931 that the existence of even one magnetic monopole anywhere would explain charge quantization, and grand-unified theories generically predict them. The MoEDAL detector at the LHC and IceCube searches have placed limits below 10⁻²⁰ monopoles per square cm per second, but none have been seen.

What is the covariant (relativistic) form of Maxwell's equations?

Define the field-strength tensor F^μν whose components are the electric and magnetic field combined: F^0i = E_i/c, F^ij = −ε^ijk B_k. Then the four Maxwell equations collapse into two: ∂_μ F^μν = μ₀ j^ν (the inhomogeneous pair, Gauss's law and Ampère-Maxwell) and ∂_μ F̃^μν = 0 (the homogeneous pair, Faraday and ∇·B = 0). This form makes Lorentz invariance manifest and is the launching point for QED. The Lagrangian density is ℒ = −¼ F_μν F^μν − j^μ A_μ.

What stays the same between two reference frames?

The electric field E and magnetic field B mix into each other under Lorentz boosts — what looks like pure E in one frame can have a B component in another. The two Lorentz-invariant scalars are E·B and E² − c²B²: every observer agrees on these two numbers. The wave equation c = 1/√(μ₀ε₀) is also invariant, which is exactly why special relativity exists: Maxwell's equations forced Einstein to abandon Galilean relativity in 1905.