BF16
What is BF16?
In one sentence: BF16, or bfloat16, is a 16-bit number format that keeps the wide range of FP32 but with less precision.
Google designed BF16 for AI. It uses the same number of exponent bits as FP32, so it rarely overflows, but fewer mantissa bits, so it is a little less precise. For neural networks, range turns out to matter more, so BF16 trains very stably.
Σ Quick math / rule of thumb: 16 bits = 2 bytes per parameter (1 sign + 8 exponent + 7 mantissa bits) — same numeric range as FP32, half the memory.
What does BF16 look like?
Most modern LLMs are trained and released in BF16.
Why does BF16 matter?
BF16 is the standard format for training and running large models today.
BF16 vs. FP16
Both use 16 bits (2 bytes) per number, but BF16 trades fractional precision bits for the wide exponent range of 32-bit floats—preventing overflow crashes during large-scale AI training.
| Dimension | BF16 | FP16 |
|---|---|---|
| Bit layout | 1 sign + 8 exponent + 7 mantissa | 1 sign + 5 exponent + 10 mantissa |
| Max numeric range | Huge (~3.4 × 10³⁸, same range as FP32) | Narrow (~65,504 max—needs loss scaling) |
| Primary sweet spot | Default format for modern LLM training | Inference on older GPUs |
Last updated · Fact-checked by The AI Math
Linking to this page from a lesson or article? <a href="https://getaimath.com/dictionary/bf16/">BF16, explained simply</a> (The AI Math Dictionary)