Calculate color temperature conversions, CIE xy CCT, and Kelvin to RGB/hex values for lighting filters and color correction with presets.
Customize This Calculator
Build your own version. Describe what you want changed, added, or compared.
Color Temperature Formula
The calculator uses three related sets of formulas: mired shift for filter correction, McCamyâs approximation for CIE xy to correlated color temperature, and a Kelvin to RGB approximation for screen color.
Filter correction formula
CIE xy to CCT formula
Kelvin to RGB formula
- K_source: original light source temperature in kelvin.
- K_target: desired converted light temperature in kelvin.
- M_source: original source temperature converted to mireds.
- M_target: target temperature converted to mireds.
- Delta_M: required mired shift. Positive values are warming corrections, and negative values are cooling corrections.
- F: mired shift value of a correction filter.
- K_corrected: estimated output kelvin after applying a filter.
- x, y: CIE 1931 chromaticity coordinates.
- CCT: correlated color temperature in kelvin.
- t: kelvin temperature divided by 100 for the RGB approximation.
- R, G, B: red, green, and blue channel values, clamped to the 0 to 255 range.
In filter correction mode, the calculator converts the source and target kelvin values to mireds because filter shifts are more consistent in mireds than in kelvin. It then compares the required shift with available filter shifts and ranks the closest matches.
In CIE xy mode, the calculator estimates correlated color temperature from chromaticity coordinates. This works best for points near the blackbody locus.
In Kelvin to RGB mode, the calculator estimates a display color for a given color temperature. The RGB result is an approximation for screens, not a physical light measurement.
Common Color Temperature Reference Values
Use these ranges to check whether a result looks reasonable for the type of light you are matching.
| Light source | Typical color temperature | Typical appearance |
|---|---|---|
| Candle or flame | 1800 K to 2000 K | Very warm amber |
| Warm household LED | 2700 K to 3000 K | Warm white |
| Tungsten studio lamp | 3200 K | Warm tungsten white |
| Cool white fluorescent | 4000 K to 4500 K | Neutral to cool white |
| Photographic daylight | 5600 K | Daylight white |
| D65 daylight | 6500 K | Slightly cool daylight |
| Blue sky shade | 9000 K to 12000 K | Cool blue-white |
| Correction type | Mired shift direction | Common use |
|---|---|---|
| CTB, color temperature blue | Negative shift | Cools a warm source, such as 3200 K tungsten toward daylight. |
| CTO, color temperature orange | Positive shift | Warms a cool source, such as daylight toward tungsten. |
| CT Straw | Positive shift | Warms daylight with a more yellow bias than CTO. |
| LED or Zircon-style correction | Positive or negative shift | Fine matching for LED fixtures and mixed LED sources. |
Color Temperature Examples
Example 1: Convert tungsten to daylight
You have a 3200 K tungsten source and want to match 5600 K daylight.
The required shift is about -134 mireds, so you need a cooling correction. A full CTB filter is close because it has a shift near -136.5 mireds.
Example 2: Estimate CCT from CIE xy
Use x = 0.3127 and y = 0.3290, which are close to D65 daylight.
The result is about 6500 K, which matches the expected daylight white range.
Color Temperature Calculator FAQ
What is the difference between kelvin and mireds?
Kelvin describes the color temperature directly. Lower kelvin values look warmer, and higher kelvin values look cooler. Mireds are calculated as 1,000,000 divided by kelvin. Filter correction is usually easier in mireds because equal mired shifts represent more consistent visual correction than equal kelvin changes.
Why does a positive mired shift make light warmer?
A positive mired shift increases the mired value. Since mireds are the inverse of kelvin, increasing mireds lowers the kelvin temperature. Lower kelvin values appear warmer, so positive mired shifts are warming corrections. Negative mired shifts raise the kelvin temperature and make the light cooler.
Is the RGB result an exact color?
No. The RGB value is an approximation for displaying a color temperature on a screen. Real light depends on the source spectrum, camera response, white balance, display calibration, and surrounding light. Use the RGB or hex output as a visual guide, not as a precise lighting specification.