CMYK (Cyan, Magenta, Yellow, Key/Black) is the colour model used in professional colour printing. RGB (Red, Green, Blue) is used for screens and digital displays. Converting between these models is essential for designers working across both print and digital media.
R = 255 × (1 − C/100) × (1 − K/100). G = 255 × (1 − M/100) × (1 − K/100). B = 255 × (1 − Y/100) × (1 − K/100). This gives the closest screen approximation of the printed colour.
Normalise RGB to 0–1. K = 1 − max(R,G,B). C = (1−R−K)/(1−K), M = (1−G−K)/(1−K), Y = (1−B−K)/(1−K). Multiply by 100 for percentages.
The mathematical conversion is exact, but the perceived colour will differ. Printing inks and screen phosphors have different colour gamuts, so some RGB colours (especially very saturated ones) cannot be accurately reproduced in CMYK print.
K stands for Key — the key colour in printing, which is black. It was abbreviated K rather than B to avoid confusion with Blue in RGB.