PDF version
Pre-requisites
I assume a working knowledge of
- Electric field
. - Geometric-description-of-electric-field
- What-is-electric-field-flux?
- What is the electric field created by a point change
? - Principle-of-superposition-of-electric-fields
TL;DR
Gauss’ law states that the net electric flux through any closed surface is proportional to the total charge enclosed inside it. Its integral form,
, is most practically used with high‐symmetry geometries (spherical, cylindrical, planar). Even though it might seem universal, using it directly for complex geometries often requires additional methods. The differential form, , underpins charge‐field relationships in Maxwell’s equations. Key insights include: flux remains invariant if charges stay within the boundary, and external charges yield zero net flux through a given surface. Applications to spherical shells, infinite planes, and wires highlight its computational utility. However, without symmetry, one typically reverts to direct integration or other approaches.
Often, one of the first wonders students encounter in electrostatics is the deceptively simple yet powerful Gauss’ law. I still recall my own initial surprise when I realized flux through any closed surface enclosing a single charge remained the same, no matter how oddly shaped that surface was. In this post, I hope to convey that same amazement while walking you through the essential details and derivations.
Question we ask: which of the following three surfaces will see the maximum flux of pass through itself?
Fig. A cone, a sphere, and a batman symbol (enclose it in the front and the back) encircle a lonely charge of magnitude
Try it yourself
Instead of taking my (well, Gauss’) word for it, try finding the flux through the cone and the circle by integrating the dot product of the local electric field and the area (note that for cone, we must account for both the lateral and the base area). Once you find the solution, make a PR at the GitHub repository please show all intermediate steps.
General form of Gauss’ law
Main statement of Gauss' law
The flux of electric field
though a closed surface (known as the Gaussian surface) is equal to the amount of change enclosed by that surface. , is the electric field, is the normal vector to the area element , is the change enclosed inside the Gaussian surface and is the permittivity-of-free-space.
- In the differential form, it is identical to:
, where is the local electric changed density.
Let us define the flux as:
Then,
Of course,
where
Proof:
Caution
I leave it upto you to decide if the following derivations are the proofs or merely consistency checks for the Gauss’ law.
Special case of spherical Gaussian surface enclosing a single charge:

Electric field by a point change:
Flux through a sphere of radius
Arbitary Gaussian surface enclosing a single charge:

Electric field by a point change:
Local flux at the indicated location:
Here,
The solid angle
Consequences of Gauss’ law
Displace the charge all you want, it won’t change the flux
The flux of
only depends on the amount of charge contained inside a Gaussian surface and not on whether or not the charge is moving inside the space enclosed by this Gaussian surface.
Remarkable property: If charges are moved around but do not cross the boundary of
A charge outside the Gaussian surface imparts net zero flux in that control surface
It is easier to see by construction that electric field lines coming out of a charge outside a Gaussian surface will pass straight through without creating any global flux.

On the impossibility of equilibrium in electrostatics
In any electrostatic field, a charge cannot be in stable equilibrium.
A single point charge 
Symmetries to the rescue
Now, one of the best ways to make Gauss’ law practical is by using symmetry arguments. Below are three major symmetry cases that come in handy.
Plannar symmetry

Consider an infinite sheet with uniform surface‐charge density
Hence, an infinite charged plane produces a constant electric field whose magnitude depends solely on
Special case:

When two parallel sheets carry equal and opposite surface‐charge densities
Outside the plates, the fields from the two sheets have opposite directions and thus cancel to zero, assuming the plates are large compared to their separation. This configuration approximates the uniform field of a parallel‐plate capacitor.
Cyliindrical symmetry

Consider an infinitely long wire with a uniform linear charge density
The field diminishes as
Spherical symmetry
Here, let us consider two cases: 1. uniformly charged sphere with charge density

For :
Here, the Gaussian surface contains the entire spherical object inside it. So, in both cases, the Gaussian surface sees a total charge of
Consequently,
For :
- Shell: Charge enclosed inside the shell for
(assuming infinitely thin shell) is . So, .
So, the final result for shell is

- Uniformly changed sphere: For uniformly charged sphere,
Substituting,
So, the final result for uniformly charged sphere is

Note
To play with the above plots, see: Gauss-law-of-electrostatics.ipynb
A critique of the Gauss’ law in the non-local form
One might wonder: is Gauss’ law too good to be true for complicated geometries? Below, I share a brief critique.
Illusion of Generality
The integral form,
can give a misleading impression that it solves any electrostatic field problem elegantly. While it is indeed general as a statement of charge–field relationships, practical usage relies heavily on symmetry arguments to simplify the surface integral.
Dependence on Symmetry
Gauss’s integral theorem is most effective when the field and geometry exhibit high symmetry (e.g., spherical, cylindrical, or planar). In such cases, one can choose a closed surface
Limitations in Complex Geometries
For configurations lacking these symmetries—such as a uniformly charged disk or other irregular charge distributions—no straightforward closed surface simplifies the flux integral. In these scenarios, one must resort to more laborious methods, like direct integration of Coulomb’s law or employing the local (differential) form combined with suitable boundary conditions.
Note:
Of course, let us be very clear that the above critique is only about the non-local form (or integral formulation) of Gauss’ law. If we use the more general differential form (or together with the Maxwell’s laws of electromagnetism, the above limitations do not apply).
Some food for throught
Gauss’ law is agnostic to the number of dimensions in the problem. In this note, we mainly looked at cases in 3D. Now, think about living in a 2D space. Answer the following:
- How does the Coulomb’s law change in 2D?
- Adapt Gauss’s law to a 2D problem, where flux becomes a line integral around a closed loop. Consider a point charge qqq in a 2D plane. Choose a circle of radius
around the charge as the “Gaussian” boundary. Compute the total radial component of along this circle and show that it is proportional to (with an appropriate constant reflecting 2D geometry). - For a hypothetical “4D” space, the electric field of a point charge might scale differently with distance. Use dimensional analysis to argue how Gauss’s law might look there, and what the “closed surface” would mean in 4D. Hint: Highlight the dimension-agnostic idea that flux = enclosed charge/
remains structurally the same, although radius-dependencies of and definitions of “surface” change with dimension.
Note: To submit answers to the questions above or in case you find a mistake in this note, please feel free to open a pull request at the repository: link to repository.
Derivation of Gauss law in differential form
Integral form:
In this post, we encountered Gauss law in integral form as,
where
Relate enclosed charge to charge density.
The enclosed charge can be expressed in terms of the volume charge density
Here,
Apply the divergence theorem
Rewrite the left side of Gauss’s law using the divergence theorem (also known as Gauss’s divergence theorem):
Gauss' divergence therorem
This is yet another significant contribution from Gauss. It relates volume integrals to fluxes at the boundaries. This theorem is more generally used throughout the Physics literature. For example, simplifying integrals in Rayleigh
Bénard convection or in Taylor Culick retractions. Rate of change of a physical quantity (see Relationship-between-rate-of-change-of-a-physical-quantity-and-its-divergence) in a volume is tied directly to its net flux across the boundary of that volume. More generally, in fluid mechanics, this principle underpins conservation laws such as mass, momentum, or energy.
Thus,
Conclude the differential form
Because this equation must hold for any volume
This is Gauss’s law in differential form. It states that the divergence of the electric field at a point is proportional to the local charge density at that point.
Significance to Maxwell’s laws of electromagnetism
The Gauss’ law of electrostatics is one of the special cases of Maxwell’s laws of electromagnetism.
Maxwell’s Equations
Differential Form
Gauss’s Law (Electric):
Gauss’s Law (Magnetic):
Faraday’s Law of Induction:
Ampère–Maxwell Law:
Integral Form
Gauss’s Law (Electric):
Gauss’s Law (Magnetic):
Faraday’s Law of Induction:
Ampère–Maxwell Law:
Conclusion
That brings us to the end of this reflective overview of Gauss’ law and its place within Maxwell’s equations. Even though the symmetrical geometries often steal the spotlight, the underlying message is that Gauss’ law is deeply fundamental—tied intimately to how charges shape and define the electric field around them. I hope these notes, with their many examples, help you see both its elegance and its limitations.
Info
Thanks for reading, and feel free to dive deeper (or suggest improvements) via the GitHub repository!
Some side notes:
- To explore some history, see: History-of-Gauss
- Here, we discuss a lot about Gaussian surfaces. The fluid dynamicist in me cannot help but point out that a Gaussian-surface-is-very-similar-to-the-control-volume-in-fluid-mechanics. 💡
Metadata
Author:: Vatsal Sanjay
Date published:: Jan 21, 2025
Date modified:: Jan 25, 2025 at 14:22
Back to main website
