RMSNorm and Scale-Only Normalization
Layer normalization both recenters and rescales a layer's activations; RMSNorm drops the recentering step entirely and rescales only by the root-mean-square, doing nearly as well at a fraction of the compute — which is why most modern large language models use it instead.
Prerequisites: Batch Normalization
Layer normalization takes each example's vector of activations and standardizes it: subtract the mean (recenter to 0) and divide by the standard deviation (rescale to unit spread), then let two learned parameters stretch and shift it back to whatever scale training actually needs. That works well, but computing a mean, then a variance around that mean, then dividing, is three passes of arithmetic over every activation, on every layer, of every token — a real cost at the scale of a modern language model. RMSNorm asks: how much of that is actually necessary?
The analogy: adjusting volume without re-centering pitch
Imagine adjusting the loudness of a recording. There are two separate things you could do: shift every sample up or down by a constant (changing where "silence" sits — recentering), and scale every sample by a factor (changing how loud the loudest parts are — rescaling). If a recording is already reasonably centered around zero and the only real problem is that its volume drifts unpredictably, you don't need the recentering step at all — a single volume knob does the job at half the effort. RMSNorm is betting that most of layer normalization's benefit for deep transformers comes from controlling scale, and that recentering was buying comparatively little.
The formulas, side by side
LayerNorm, for an activation vector with mean and standard deviation :
In words: subtract the mean, divide by the standard deviation, then apply a learned scale and shift .
RMSNorm skips the mean subtraction and divides only by the root-mean-square:
In words: measure the typical magnitude of the vector by averaging its squared entries and taking the square root (never subtracting a mean first), divide every entry by that number, and apply a single learned scale — there is no learned shift and no recentering step at all.
Worked example 1: RMSNorm by hand
Take . Sum of squares: . Mean of squares: . RMS . Divide each entry: . With , that's the RMSNorm output — no mean was ever computed or subtracted.
Worked example 2: comparing to LayerNorm on the same vector
Same . Mean . Variance , so . LayerNorm output (with ): . The outputs differ meaningfully from RMSNorm's — LayerNorm shifted everything relative to the mean of 2 first, RMSNorm never did. Both still succeed at the main goal: neither output has entries that have grown or shrunk to an extreme scale, which is what keeps a deep stack of these layers numerically stable.
RMSNorm rescales an activation vector by its root-mean-square, , and applies a single learned scale — no mean subtraction, no learned shift — trading LayerNorm's extra recentering step for cheaper computation at a similar level of training stability.
What this means in practice
RMSNorm is the default normalization in most contemporary transformer architectures because it removes roughly a third of the arithmetic (no mean, no parameter) while empirically matching LayerNorm's training stability on large models; it's the reason a quant reading a modern LLM's architecture diagram sees "RMSNorm" rather than "LayerNorm" at nearly every block. The saved computation is genuinely material at the scale of billions of parameters and trillions of training tokens, even though the difference in behavior on any single small vector, as above, looks modest.
The common confusion is assuming RMSNorm is simply "LayerNorm without the learned shift " and nothing else changes. The bigger difference is upstream: RMSNorm never computes or subtracts a mean at all, so activations that happen to be systematically biased away from zero stay biased after RMSNorm, whereas LayerNorm would have corrected that. RMSNorm works well in practice because transformer activations tend not to have large systematic offsets to begin with — not because recentering is unimportant in general.
Related concepts
Practice in interviews
Further reading
- Zhang & Sennrich, Root Mean Square Layer Normalization (2019)