Sub topic 5
Warm and cool colours
This chapter assumes you can read hue, saturation, and lightness values and find a hue on the colour wheel from the earlier chapters. You should also know that hue is measured as an angle from 0 to 359 degrees. Here you will learn to split the wheel into warm and cool regions, why that split is partly a matter of comparison, and how colour temperature affects the harmonies in later chapters.
What colour temperature means
Colour temperature is a design term. It describes the feeling a hue gives, not a physical measurement. Reds, oranges, and yellows are called warm because they recall fire, sunlight, and heat. Blues, blue-greens, and some violets are called cool because they recall water, ice, and shade.
Do not confuse this with the photographic "colour temperature" measured in kelvins. In photography, a low-kelvin light looks orange and a high-kelvin light looks blue. Designers use "warm" and "cool" for the hue of a colour itself, and they do not read the numbers in kelvins.
Temperature is a property of hue. Saturation and lightness change how strongly you notice it, but they do not change which side of the wheel a colour sits on. A pale pink and a deep crimson are both warm.
Where the boundary falls
The wheel does not divide cleanly into two halves. Two hues sit at the extremes: red-orange to orange is the warmest, and a blue near the cyan-blue boundary is the coolest. Between them, a colour's temperature depends on how close it sits to either extreme.
On the HSL wheel used in this tutorial's code, a practical split looks like this:
| Region | Hue angles (HSL) | Typical colours | Usual effect |
|---|---|---|---|
| Warm | 345 to 75 | Red, orange, yellow | Energy, urgency, friendliness |
| Transitional | 75 to 165 | Yellow-green, green | Neutral, natural, balanced |
| Cool | 165 to 255 | Cyan, azure, blue | Calm, trust, distance |
| Transitional | 255 to 345 | Violet, purple, magenta | Ambiguous, creative, luxurious |
The boundaries are conventions. Other authors draw them a little differently, and none of the numbers above is a standard. Treat them as defaults that you can adjust.
The two transitional bands are where most mistakes happen. Green and violet can each lean either way. A yellow-green reads warm and a blue-green reads cool. A red-violet reads warm and a blue-violet reads cool. These are the colours where temperature depends on context.
Temperature is relative
A colour is rarely warm or cool in isolation. You judge it against what is next to it. A green looks cool beside orange and warm beside blue. A grey patch placed on a red background tends to look slightly cooler than the same grey on a blue background.
The same applies within one hue. Every hue has a warm version and a cool version, which painters call its bias. For example:
- A red that leans toward orange (hue near 5) is a warm red. A red that leans toward magenta (hue near 350) is a cool red.
- A blue that leans toward green (hue near 195) is a warm blue compared with one that leans toward violet (hue near 240).
- A yellow with a trace of orange is warm. A yellow with a trace of green is cooler.
This matters when you build a palette. Two reds that are both "red" can clash because one is warm-biased and the other cool-biased. When a palette looks slightly off but the hues seem correct, check the bias first.
How warm and cool colours behave on a page
Warm and cool colours affect how a layout reads. These effects are strong tendencies, not laws.
- Advance and recede. Warm hues tend to seem closer to the viewer, and cool hues tend to seem further away. A warm button on a cool background pops forward. A cool background pattern stays behind the content.
- Attention. Saturated warm colours attract the eye faster than cool ones of the same lightness. This is why alert badges and calls to action are often red or orange.
- Mood. Warm palettes feel energetic or intimate. Cool palettes feel calm, clean, or formal. Cultural associations vary, so test them with your audience instead of assuming.
- Lightness interacts with temperature. A dark, desaturated warm colour such as brown can feel less "hot" than a bright cool one such as electric blue. Temperature is only one of several signals.
Colour temperature does not replace contrast. A warm orange on a warm yellow background has low contrast even though both are vivid. Contrast and accessibility get their own chapter later.
Temperature inside the three harmonies
Each harmony from the plan has a typical temperature profile.
- Complementary. The pair often falls on opposite sides of the temperature boundary. Orange (hue 30) and blue (hue 210) are the classic example, a full warm-cool contrast. This is not guaranteed. Green (120) and red-magenta (300) are both transitional, so the pair has less temperature contrast.
- Analogous. Neighbouring hues usually share a temperature. An analogous palette centred on 30 is warm throughout. One centred on 210 is cool throughout. These palettes feel unified but can look flat without a lightness change.
- Triadic. Three hues 120 degrees apart almost always include both temperatures. The set 0, 120, 240 has a warm red, a transitional green, and a cool blue. Choosing which one dominates sets the overall feel.
A useful workflow is to pick the temperature you want first and the harmony second. If you want a calm interface, choose a cool base hue. Then add a small warm accent from a complementary or triadic relationship.
Measuring warmth in code
The following function scores warmth as closeness to orange, which it takes as the warmest hue at 30 degrees. A score of 1 is warmest and 0 is coolest. The classification then uses the bands from the table. Both are simplifications of a perceptual idea, so use them for quick checks and do not treat them as a standard.
function angularDistance(a, b) {
const diff = (((a - b) % 360) + 360) % 360;
return diff > 180 ? 360 - diff : diff;
}
function warmthScore(hue) {
return 1 - angularDistance(hue, 30) / 180;
}
function classifyTemperature(hue) {
const h = ((hue % 360) + 360) % 360;
if (h >= 345 || h < 75) return "warm";
if (h >= 165 && h < 255) return "cool";
return "transitional";
}
for (const hue of [0, 30, 120, 210, 270, 330]) {
console.log(
hue,
classifyTemperature(hue),
warmthScore(hue).toFixed(2)
);
}
// 0 warm 0.83
// 30 warm 1.00
// 120 transitional 0.50
// 210 cool 0.00
// 270 transitional 0.33
// 330 transitional 0.67Notice that 330 is classified as transitional, but its score of 0.67 shows it leans warm. That is the red-violet case described earlier. If you need a yes or no answer for a particular design, you can compare the score with a threshold such as 0.6 instead of using the bands.
Applying it in CSS
A cool-dominant interface with a single warm accent follows the advance-and-recede effect. The base hue is 210, and the accent is its complement, found by adding 180 and wrapping into the 0 to 359 range. Here 210 + 180 = 390, which wraps to 30.
:root {
--base-hue: 210;
--accent-hue: 30;
}
body {
background: hsl(var(--base-hue) 30% 96%);
color: hsl(var(--base-hue) 40% 15%);
}
.panel {
background: hsl(var(--base-hue) 45% 88%);
}
.cta {
background: hsl(var(--accent-hue) 90% 45%);
color: white;
}Most of the page is cool and low in saturation, so the warm button is the first thing the eye finds. Check the button's text contrast before shipping, because white on a mid-lightness orange can fall below the readable threshold.
Common errors
- Treating green and violet as fixed. Decide their temperature from their bias and surroundings.
- Mixing biases. A warm red and a cool red in the same palette can look like a mistake. Pick one bias per hue family.
- Using temperature as the only signal. Colour-blind users may not see the warm-cool difference, so pair it with lightness or shape.
- Over-warming a dark theme. Large areas of saturated warm colour tire the eye. Keep them for small accents.
- Assuming one wheel. The RYB wheel places green and blue differently than the RGB wheel, so a colour's neighbours, and sometimes its apparent temperature, shift with the model.
Exercise
A designer builds an analogous palette from hues 150, 180, and 210 for a wellness app. Using the bands in this chapter, which temperatures do these hues have, and what single change would add a warm accent that still follows a harmony rule?
Show answer
Hue 150 is transitional (green), 180 is cool (cyan), and 210 is cool (blue), so the palette is cool overall with a green lean. To add a warm accent, take the complement of the central hue: 180 + 180 = 360, which wraps to 0, a red. Using it sparingly, for example as a low-saturation coral on buttons, gives the warm-cool contrast without breaking the cool dominance.
Exercise
Using the warmthScore function, which scores a hue by its angular distance from 30, what is the score for hue 300, and what does the result suggest about that colour's temperature?
Show answer
The distance from 300 to 30 is 90 degrees (the wrapped difference is 270, and 360 - 270 = 90). The score is 1 - 90/180 = 0.5. A score of 0.5 sits in the middle of the scale, which agrees with the classification of magenta as transitional. Its temperature depends on its bias and its neighbours.